Closed Bug 18021 Opened 25 years ago Closed 25 years ago

Use nsSpecialSystemDirectory class to get temporary directory

Categories

(MailNews Core :: MIME, defect, P3)

defect

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: michael.j.lowe, Assigned: rhp)

References

Details

The files:

1. mimedrft.cpp
2. nsEmitterUtils.cpp

should use the class "nsSpecialSystemDirectory"
instead of the function "GetTheTempDirectoryOnTheSystem" to get the temporary
directory.
QA Contact: lchiang → ppandit
Status: NEW → ASSIGNED
Target Milestone: M13
Feel free to jump in if you would like :-)

- rhp
Vaguely related to that would be the possibility not to use the system temp
directory. Instead the cache directory could be used (uppon user's choice) or a
different one.
Philippe Maestri
*** Bug 19182 has been marked as a duplicate of this bug. ***
Summary: Use nsSpecialSystemDirectory class to get temporary directory → FIXED: Use nsSpecialSystemDirectory class to get temporary directory
Made these changes...will checkin when the tree opens.

- rhp
Status: ASSIGNED → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Summary: FIXED: Use nsSpecialSystemDirectory class to get temporary directory → Use nsSpecialSystemDirectory class to get temporary directory
Should be fixed now.

- rhp
Status: RESOLVED → REOPENED
Some more instances you might like to fix:

/mailnews/compose/tests/compose2/test2.cpp
/mailnews/mapi/hook/mapihook.cpp
/mailnews/mapi/mapi32/mapiutl.cpp
Resolution: FIXED → ---
Status: REOPENED → RESOLVED
Closed: 25 years ago25 years ago
Resolution: --- → FIXED
Thanks for the comments, but mozilla\mailnews\mapi is a Windows only MAPI DLL
so the calls would equate to the same and the other is a test harness program
and I'm sort of swamped with bugs to fix those, verify on 3 platforms, etc..
:-)

- rhp
Status: RESOLVED → VERIFIED
Current mozilla text search for GetTheTempDirectoryOnTheSystem shows:
/mailnews/compose/tests/compose2/test2.cpp, line 90 --
GetTheTempDirectoryOnTheSystem(void)
/mailnews/compose/tests/compose2/test2.cpp, line 164 -- char *tDir =
GetTheTempDirectoryOnTheSystem();
/mailnews/mapi/hook/mapihook.cpp, line 1096 --
GetTheTempDirectoryOnTheSystem(void)
/mailnews/mapi/hook/mapihook.cpp, line 1151 -- LPSTR szTempPath =
GetTheTempDirectoryOnTheSystem();
/mailnews/mapi/mapi32/mapiutl.cpp, line 330 --
GetTheTempDirectoryOnTheSystem(void)
/mailnews/mapi/mapi32/mapiutl.cpp, line 369 -- LPSTR szTempPath =
GetTheTempDirectoryOnTheSystem();
/mailnews/mapi/mapi32/mapiutl.cpp, line 657 -- char *szTempPath =
GetTheTempDirectoryOnTheSystem();

Current search for nsSpecialSystemDirectory shows:
/mailnews/mime/emitters/src/nsEmitterUtils.cpp, line 34 -- #include
"nsSpecialSystemDirectory.h"
/mailnews/mime/emitters/src/nsEmitterUtils.cpp, line 100 -- nsFileSpec *tmpSpec
= new
nsFileSpec(nsSpecialSystemDirectory(nsSpecialSystemDirectory::OS_TemporaryDirect
ory));
/mailnews/mime/emitters/src/nsEmitterUtils.cpp, line 121 -- nsFileSpec *tmpSpec
= new
nsFileSpec(nsSpecialSystemDirectory(nsSpecialSystemDirectory::OS_TemporaryDirect
ory));
/mailnews/mime/src/mimedrft.cpp, line 49 -- #include
"nsSpecialSystemDirectory.h"
/mailnews/mime/src/mimedrft.cpp, line 115 -- nsFileSpec *tmpSpec = new
nsFileSpec(nsSpecialSystemDirectory(nsSpecialSystemDirectory::OS_TemporaryDirect
ory));

VERIFIED
Product: MailNews → Core
Product: Core → MailNews Core
You need to log in before you can comment on or make changes to this bug.