Closed
Bug 5365
Opened 26 years ago
Closed 15 years ago
use nsCRT::strtok() instead of strtok()
Categories
(MailNews Core :: Backend, defect, P3)
MailNews Core
Backend
Tracking
(Not tracked)
RESOLVED
WORKSFORME
People
(Reporter: sspitzer, Unassigned)
References
Details
Attachments
(1 file)
(deleted),
patch
|
neil
:
review-
|
Details | Diff | Splinter Review |
I wrote some code that used strtok() and alecf pointed out that strtok() is not
thread safe. There is a thread safe version nsCRT::strtok() that I'm now using.
This bug is to remind me to replace strtok() [and possibly XP_STRTOK] with
nsCRT::strtok(). Imapstrok_r() should be fine how it is.
Reporter | ||
Updated•26 years ago
|
Status: NEW → ASSIGNED
Target Milestone: M6
Reporter | ||
Comment 1•26 years ago
|
||
setting target to M6
Comment 2•26 years ago
|
||
cc'ing chuang since the LDAP prefs code also uses strtok, so Candice you'll need
to make this change if/when you port that code.
Reporter | ||
Updated•26 years ago
|
Target Milestone: M6 → M9
Reporter | ||
Comment 3•26 years ago
|
||
moving to m9.
Should the platform be all? Or, is this a platform parity bug? Thanks.
Reporter | ||
Updated•26 years ago
|
OS: Linux → All
Reporter | ||
Comment 5•26 years ago
|
||
marking OS all.
it is not a PP bug.
Comment 6•26 years ago
|
||
Does this need to be fixed for M9? If not, we should move this.
Reporter | ||
Updated•26 years ago
|
Target Milestone: M9 → M10
Reporter | ||
Comment 7•26 years ago
|
||
moving to m10.
what we need to do is go through http://lxr.mozilla.org/seamonkey/ident?i=strtok
and see where we are using nsCRT::strtok and where we are using strtok.
regular strtok is not thread safe.
Reporter | ||
Updated•26 years ago
|
Target Milestone: M10 → M11
Reporter | ||
Comment 8•26 years ago
|
||
moving to m11. not dogfood.
Comment 9•25 years ago
|
||
Triage to M15
Updated•25 years ago
|
Assignee: sspitzer → bienvenu
Status: ASSIGNED → NEW
Comment 10•25 years ago
|
||
I'll take this.
Comment 13•25 years ago
|
||
Until/Unless 28952 is fixed, it would be wrong to fix this since I would be
introducing bugs.
Comment 14•24 years ago
|
||
until 28952 is fixed, this won't be fixed. I'm moving this to future, since bug
28952 hasn't seen any action.
Target Milestone: M18 → Future
Comment 15•23 years ago
|
||
the one instance of strtok left in the mailnews code, in
nsNNTPProtocol::DisplayNewsRCResponse(), doesn't need to be thread-safe because
this code is only ever called on one thread. I suspect that's true for the
remaining instances of XP_STRTOK in nsDirPrefs.cpp.
QA Contact: ppandit → stephend
Comment 16•22 years ago
|
||
After comparing a couple of queries:
http://lxr.mozilla.org/seamonkey/ident?i=strtok
http://lxr.mozilla.org/seamonkey/search?string=nsCRT%3A%3Astrtok
it turns out that the only places where we are still using strtok() in the
mailnews component are the following:
* mailnews/addrbook/src/nsDirPrefs.cpp:
o line 2248
o line 2251
o line 2256
o line 2261
o line 2379
o line 2383
* mailnews/news/src/nsNNTPProtocol.cpp:
o line 4127
Updated•20 years ago
|
Product: MailNews → Core
Comment 17•17 years ago
|
||
Down to one place: nsNNTPProtocol.cpp
Comment 18•17 years ago
|
||
One remaining instance, we may as well fix it, be consistent and close this bug.
I think this is the fix we want.
Assignee: bienvenu → bugzilla
Attachment #323411 -
Flags: superreview?(neil)
Attachment #323411 -
Flags: review?(neil)
Comment 19•17 years ago
|
||
Comment on attachment 323411 [details] [diff] [review]
The fix
This isn't right, NS_strtok changes group.
Attachment #323411 -
Flags: superreview?(neil)
Attachment #323411 -
Flags: review?(neil)
Attachment #323411 -
Flags: review-
Updated•16 years ago
|
QA Contact: stephend → backend
Assignee | ||
Updated•16 years ago
|
Product: Core → MailNews Core
Comment 20•16 years ago
|
||
Nominating wanted-thunderbird3 because of a partial patch and that it's down to one location only.
Flags: wanted-thunderbird3?
Comment 21•15 years ago
|
||
Bug 311774 removed the last remaining instance in nsNNTPProtocol.cpp. Therefore resolving this bug as WFM.
Assignee: bugzilla → nobody
Status: ASSIGNED → RESOLVED
Closed: 15 years ago
Flags: wanted-thunderbird3?
Resolution: --- → WORKSFORME
Target Milestone: Future → ---
You need to log in
before you can comment on or make changes to this bug.
Description
•