~ubuntu-branches/ubuntu/karmic/fastjar/karmic

« back to all changes in this revision

Viewing changes to jartool.c

  • Committer: Bazaar Package Importer
  • Author(s): Matthias Klose
  • Date: 2009-01-10 12:54:48 UTC
  • Revision ID: james.westby@ubuntu.com-20090110125448-ki493ln0mfztr2ms
Tags: 2:0.97-1ubuntu2
* Fix segfault in jartool.c (Arthur Loiret).
* Revert the previous change.

Show diffs side-by-side

added added

removed removed

Lines of Context:
820
820
  int mod_time; /* file modification time */
821
821
  struct zipentry *ze;
822
822
 
 
823
  current_time = time(NULL);
 
824
  if(current_time == (time_t)-1)
 
825
    exit_on_error("time");
 
826
 
823
827
  mod_time = unix2dostime(&current_time);  
824
828
  
825
829
  /* If we are creating a new manifest, create a META-INF directory entry */
828
832
 
829
833
    memset((file_header + 12), '\0', 16); /*clear mod time, crc, size fields*/
830
834
  
831
 
    current_time = time(NULL);
832
 
    if(current_time == (time_t)-1)
833
 
      exit_on_error("time");
834
 
 
835
835
    PACK_UB2(file_header, LOC_EXTRA, 0);
836
836
    PACK_UB2(file_header, LOC_COMP, 0);
837
837
    PACK_UB2(file_header, LOC_FNLEN, nlen);