Ticket #664: fix_sha1.patch
File fix_sha1.patch, 643 bytes (added by , 13 years ago) |
---|
-
simple-sha1.scm
40 40 (string->list digest))))) 41 41 42 42 (define (sha1sum fname) 43 (and (file-exists? fname) 44 (not (directory? fname)) 43 45 (let* ((fd (file-open fname open/rdonly)) 44 46 (fsize (file-size fd)) 45 47 (ctxt (allocate context-size)) … … 56 58 (string-concatenate 57 59 (map (lambda (c) 58 60 (string-pad (number->string (char->integer c) 16) 2 #\0)) 59 (string->list digest))))) 61 (string->list digest)))))) 60 62 61 63 )