diff options
Diffstat (limited to 'libglusterfs/src')
| -rw-r--r-- | libglusterfs/src/md5.c | 2 | ||||
| -rw-r--r-- | libglusterfs/src/spec.y | 1 | 
2 files changed, 3 insertions, 0 deletions
diff --git a/libglusterfs/src/md5.c b/libglusterfs/src/md5.c index 6fd6ecbf780..5f0d0d157bf 100644 --- a/libglusterfs/src/md5.c +++ b/libglusterfs/src/md5.c @@ -294,6 +294,8 @@ int main(int argc, char *argv[])  		while ((i = fread(buf, 1, sizeof buf, f)) > 0)  			md5_update(&ctx, buf, i); +		fclose(f); +  		md5_result(&ctx, md5sum);  		for (j = 0; j < MD5_DIGEST_LEN; j++) diff --git a/libglusterfs/src/spec.y b/libglusterfs/src/spec.y index e5d68b42106..ec9101a2c21 100644 --- a/libglusterfs/src/spec.y +++ b/libglusterfs/src/spec.y @@ -518,6 +518,7 @@ parse_backtick (FILE *srcfp, FILE *dstfp)  					result = realloc (result,                                                            2 * cmd_buf_size);                                          if (result == NULL) { +                                                free (cmd);                                                  return -1;                                          }                                  }  | 
