summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authorSimon Que <sque@chromium.org>2013-01-17 11:18:20 -0800
committerBen Hutchings <ben@decadent.org.uk>2017-11-11 13:34:41 +0000
commit8264be3726a0d05711b1df810f2181c48e4c4cf0 (patch)
treee54ea36f33b0dcf8788f6c994e672b8a15d8093b /fs
parent8434628c8fcfbce59c78b2a48d2e405e901c19d3 (diff)
eCryptfs: initialize payload_len in keystore.c
commit fa5199648e273a5e3e80aca41c1eb53700438dc1 upstream. This is meant to remove a compiler warning. It should not make any functional change. payload_len should be initialized when it is passed to write_tag_64_packet() as a pointer. If that call fails, this function should return early, and payload_len won't be used. Signed-off-by: Simon Que <sque@chromium.org> Signed-off-by: Tyler Hicks <tyhicks@canonical.com> [bwh: Backported to 3.2: adjust context] Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Diffstat (limited to 'fs')
-rw-r--r--fs/ecryptfs/keystore.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/ecryptfs/keystore.c b/fs/ecryptfs/keystore.c
index 5ce56e7598b1..848b3031c908 100644
--- a/fs/ecryptfs/keystore.c
+++ b/fs/ecryptfs/keystore.c
@@ -1152,7 +1152,7 @@ decrypt_pki_encrypted_session_key(struct ecryptfs_auth_tok *auth_tok,
struct ecryptfs_message *msg = NULL;
char *auth_tok_sig;
char *payload = NULL;
- size_t payload_len;
+ size_t payload_len = 0;
int rc;
rc = ecryptfs_get_auth_tok_sig(&auth_tok_sig, auth_tok);