--- fastjar-0.97/jartool.c 2008-10-15 18:35:37.000000000 +0200 +++ fastjar-0.97/jartool.c-gil 2010-02-03 17:52:35.000000000 +0100 @@ -820,6 +820,10 @@ int mod_time; /* file modification time */ struct zipentry *ze; + current_time = time(NULL); + if(current_time == (time_t)-1) + exit_on_error("time"); + mod_time = unix2dostime(¤t_time); /* If we are creating a new manifest, create a META-INF directory entry */ @@ -828,10 +832,6 @@ memset((file_header + 12), '\0', 16); /*clear mod time, crc, size fields*/ - current_time = time(NULL); - if(current_time == (time_t)-1) - exit_on_error("time"); - PACK_UB2(file_header, LOC_EXTRA, 0); PACK_UB2(file_header, LOC_COMP, 0); PACK_UB2(file_header, LOC_FNLEN, nlen);