]> granicus.if.org Git - python/commitdiff
Temporary debug for Windows buildbots.
authorAntoine Pitrou <solipsis@pitrou.net>
Wed, 25 Jan 2012 13:39:21 +0000 (14:39 +0100)
committerAntoine Pitrou <solipsis@pitrou.net>
Wed, 25 Jan 2012 13:39:21 +0000 (14:39 +0100)
Python/import.c

index 9876aad40070c9c7533539c9eecae2417eb17586..79cd70827ae6ba9844bf660b354899d1457e3720 100644 (file)
@@ -907,6 +907,11 @@ write_compiled_module(PyCodeObject *co, char *cpathname, struct stat *srcstat)
     }
     /* Now write the true mtime */
     fseek(fp, 4L, 0);
+    if (mtime >= LONG_MAX) {
+        fprintf(stderr, "** mtime=%ld > %ld (%ld, %ld)\n", mtime, LONG_MAX, sizeof(time_t), sizeof(srcstat->st_mtime));
+        assert(0);
+        /* can't get here */
+    }
     assert(mtime < LONG_MAX);
     PyMarshal_WriteLongToFile((long)mtime, fp, Py_MARSHAL_VERSION);
     fflush(fp);