Fossil

Check-in [4027ad4b]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:fixed [9ff56ae8a6] - "fossil sha" crash
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | dead-end
Files: files | file ages | folders
SHA1:4027ad4b7e5d18294b0c102b242167df8314a599
User & Date: ron 2010-02-06 20:20:59
References
2010-02-08
17:22 New ticket [e42448ed] "co --latest" not working anymore?. artifact: 7414994f user: bharder
2010-02-06
20:21 Fixed ticket [9ff56ae8]: "fossil sha xxx" crashes w/ assert if "xxx" doesn't exist plus 2 other changes artifact: 7933badd user: ron
Context
2010-02-08
14:20
Added better error message when trying to remove a directory. Closed-Leaf check-in: 1761fee0 user: jeremy_c tags: dead-end
2010-02-06
20:20
fixed [9ff56ae8a6] - "fossil sha" crash check-in: 4027ad4b user: ron tags: dead-end
17:25
Windows only: remove duplicate code from sqlite3.c in db.c check-in: 2f58d48c user: ron tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/sha1.c.

   609    609     Blob cksum;
   610    610     
   611    611     for(i=2; i<g.argc; i++){
   612    612       if( g.argv[i][0]=='-' && g.argv[i][1]==0 ){
   613    613         blob_read_from_channel(&in, stdin, -1);
   614    614         sha1sum_blob(&in, &cksum);
   615    615       }else{
          616  +	  if (access(g.argv[i], R_OK)) {
          617  +		  fossil_fatal("cannot open %s", g.argv[i]);
          618  +	  }
   616    619         sha1sum_file(g.argv[i], &cksum);
   617    620       }
   618    621       printf("%s  %s\n", blob_str(&cksum), g.argv[i]);
   619    622       blob_reset(&cksum);
   620    623     }
   621    624   }