summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGregory P. Smith <greg@krypto.org>2013-11-23 20:21:28 (GMT)
committerGregory P. Smith <greg@krypto.org>2013-11-23 20:21:28 (GMT)
commit2b38fc187c2a764b7608cd262de5a2777a77f4c8 (patch)
treefbf43d9060c70209ff374395cd2701ceb9dfe19e
parent2489bd83f5762c4e343d8d93af4cd5514eb5c67d (diff)
downloadcpython-2b38fc187c2a764b7608cd262de5a2777a77f4c8.zip
cpython-2b38fc187c2a764b7608cd262de5a2777a77f4c8.tar.gz
cpython-2b38fc187c2a764b7608cd262de5a2777a77f4c8.tar.bz2
gcc doesn't realize that dummy is always initialized by the function call
and warns about potential uninitialized use. Silence that by initializing it to null.
-rw-r--r--Modules/_pickle.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_pickle.c b/Modules/_pickle.c
index 4e0d86c..11e07b3 100644
--- a/Modules/_pickle.c
+++ b/Modules/_pickle.c
@@ -1132,7 +1132,7 @@ _Unpickler_Read(UnpicklerObject *self, char **s, Py_ssize_t n)
(self->frame_end_idx == -1 ||
self->frame_end_idx <= self->next_read_idx)) {
/* Need to read new frame */
- char *dummy;
+ char *dummy = NULL;
unsigned char *frame_start;
size_t frame_len;
if (_Unpickler_ReadUnframed(self, &dummy, FRAME_HEADER_SIZE) < 0)