Mercurial > pidgin
comparison src/log.c @ 13974:e757e5d04846
[gaim-migrate @ 16532]
On my system and in all the documentation I can find, the tm_zone field of the tm struct, if present, is a (char *), not a (const char *). This fixes two (harmless) compilation warnings resulting from the cast to (const char *).
committer: Tailor Script <tailor@pidgin.im>
| author | Evan Schoenberg <evan.s@dreskin.net> |
|---|---|
| date | Thu, 20 Jul 2006 18:54:26 +0000 |
| parents | b355f7ed1814 |
| children | f94309c7c480 |
comparison
equal
deleted
inserted
replaced
| 13973:9c0885611b27 | 13974:e757e5d04846 |
|---|---|
| 105 /* XXX: This is so wrong... */ | 105 /* XXX: This is so wrong... */ |
| 106 if (log->tm->tm_zone != NULL) | 106 if (log->tm->tm_zone != NULL) |
| 107 { | 107 { |
| 108 char *tmp = g_locale_from_utf8(log->tm->tm_zone, -1, NULL, NULL, NULL); | 108 char *tmp = g_locale_from_utf8(log->tm->tm_zone, -1, NULL, NULL, NULL); |
| 109 if (tmp != NULL) | 109 if (tmp != NULL) |
| 110 log->tm->tm_zone = (const char *)tmp; | 110 log->tm->tm_zone = tmp; |
| 111 else | 111 else |
| 112 /* Just shove the UTF-8 bytes in and hope... */ | 112 /* Just shove the UTF-8 bytes in and hope... */ |
| 113 log->tm->tm_zone = (const char *)g_strdup(log->tm->tm_zone); | 113 log->tm->tm_zone = (char *)g_strdup(log->tm->tm_zone); |
| 114 } | 114 } |
| 115 #endif | 115 #endif |
| 116 } | 116 } |
| 117 | 117 |
| 118 if (log->logger && log->logger->create) | 118 if (log->logger && log->logger->create) |
