aboutsummaryrefslogtreecommitdiff
path: root/helper.c
diff options
context:
space:
mode:
authorFranklin Wei <me@fwei.tk>2018-06-15 18:31:34 -0400
committerFranklin Wei <me@fwei.tk>2018-06-15 18:31:34 -0400
commitd0b708e594f366a4acbd6c2dde638abcdf92c364 (patch)
tree58747cd2a3daaa129b3bb616dbcd21747cca7ab6 /helper.c
parent30a65725a518dfeebe2f4e16f914fc2c712188fa (diff)
downloadcsaa-d0b708e594f366a4acbd6c2dde638abcdf92c364.zip
csaa-d0b708e594f366a4acbd6c2dde638abcdf92c364.tar.gz
csaa-d0b708e594f366a4acbd6c2dde638abcdf92c364.tar.bz2
csaa-d0b708e594f366a4acbd6c2dde638abcdf92c364.tar.xz
Clean up memory leaks and uninitialized values
Diffstat (limited to 'helper.c')
-rw-r--r--helper.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/helper.c b/helper.c
index 2474d87..617e8d0 100644
--- a/helper.c
+++ b/helper.c
@@ -56,7 +56,7 @@ struct user_request req_filecreate(const struct trusted_module *tm,
const hash_t *file_comp, const int *file_orders, size_t file_n)
{
/* construct a request to create a file */
- struct user_request req;
+ struct user_request req = req_null;
req.idx = file_node->idx;
req.user_id = user_id;
req.type = ACL_UPDATE;
@@ -96,7 +96,7 @@ struct user_request req_filemodify(const struct trusted_module *tm,
hash_t fileval)
{
/* modification */
- struct user_request req;
+ struct user_request req = req_null;
req.type = FILE_UPDATE;
req.idx = file_node->idx;