Sfoglia il codice sorgente

Let's not use the non-standard timegm() even if __GNUC__ is defined

rdb 15 anni fa
parent
commit
47649afc5b
1 ha cambiato i file con 4 aggiunte e 1 eliminazioni
  1. 4 1
      panda/src/downloader/httpDate.cxx

+ 4 - 1
panda/src/downloader/httpDate.cxx

@@ -210,7 +210,10 @@ HTTPDate(const string &format) {
   }
 
   // Everything checks out; convert the date.
-#ifdef __GNUC__
+  // rdb made this an #if 0 check as timegm is a nonstandard extension
+  // so it fails in some situations even if the compiler defines __GNUC__
+#if 0
+
   _time = timegm(&t);
 
 #else  // __GNUC__