Closed
Bug 14708
Opened 25 years ago
Closed 25 years ago
Fix small compiler warning in nsScriptableDateFormat.cpp
Categories
(Core :: Internationalization, defect, P3)
Core
Internationalization
Tracking
()
VERIFIED
FIXED
People
(Reporter: colin, Assigned: colin)
Details
mktime returns (time_t)-1 in the event of an error, so the -1 in the
attached needs casting to time_t.
Index: nsScriptableDateFormat.cpp
===================================================================
RCS file: /cvsroot/mozilla/intl/locale/src/nsScriptableDateFormat.cpp,v
retrieving revision 1.6
diff -u -r1.6 nsScriptableDateFormat.cpp
--- nsScriptableDateFormat.cpp 1999/09/08 20:08:15 1.6
+++ nsScriptableDateFormat.cpp 1999/09/23 14:00:57
@@ -115,7 +115,7 @@
tmTime.tm_yday = tmTime.tm_wday = 0;
tmTime.tm_isdst = -1;
timetTime = mktime(&tmTime);
- if (-1 != timetTime) {
+ if ((time_t)-1 != timetTime) {
rv = aDateTimeFormat->FormatTime(aLocale, dateFormatSelector,
timeFormatSelector,
timetTime, mStringOut);
if (NS_SUCCEEDED(rv)) {
Assignee | ||
Comment 1•25 years ago
|
||
I can check this fix in (assuming I get approval from Chris H) if you
want to give me the go-ahead.
Updated•25 years ago
|
Assignee: ftang → nhotta
Comment 2•25 years ago
|
||
nhotta, please review this . This is your code.
Updated•25 years ago
|
Assignee: nhotta → colin
Comment 3•25 years ago
|
||
The patch looks fine to me.
Assignee | ||
Updated•25 years ago
|
Status: NEW → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 4•25 years ago
|
||
I just checked this in (rev 1.7) with Chris' permission.
Updated•25 years ago
|
QA Contact: teruko → nhotta
Comment 5•25 years ago
|
||
Changed QA contact to nhotta@netscape.com.
Hotta san, please just mark this bug to verified.
Updated•25 years ago
|
Status: RESOLVED → VERIFIED
Comment 6•25 years ago
|
||
Verified, I checked the rev 1.7.
You need to log in
before you can comment on or make changes to this bug.
Description
•