author | Marc Fournier <marc.fournier@camptocamp.com> | |
Tue, 2 Dec 2014 23:10:54 +0000 (00:10 +0100) | ||
committer | Marc Fournier <marc.fournier@camptocamp.com> | |
Tue, 2 Dec 2014 23:10:54 +0000 (00:10 +0100) | ||
commit | a574cf03dfd266e780f61515d7a0b910cc3afac1 | |
tree | 8e92888b520483372516cdf8c1af91b0e820794f | tree | snapshot |
parent | 3641c34781b6e1c3cac349d0d3d0659a74fdcdbf | commit | diff |
zookeeper: initialize a variable
If the loop on line 132 doesn't iterate at least once, the function would
return the "sk" variable uninitialized.
This fixes the following build error:
cc1: warnings being treated as errors
zookeeper.c: In function 'zookeeper_read':
zookeeper.c:107: warning: 'sk' may be used uninitialized in this function
make[3]: *** [zookeeper.lo] Error 1
(caught by gcc version 4.1.2 on EL5)
If the loop on line 132 doesn't iterate at least once, the function would
return the "sk" variable uninitialized.
This fixes the following build error:
cc1: warnings being treated as errors
zookeeper.c: In function 'zookeeper_read':
zookeeper.c:107: warning: 'sk' may be used uninitialized in this function
make[3]: *** [zookeeper.lo] Error 1
(caught by gcc version 4.1.2 on EL5)
src/zookeeper.c | diff | blob | history |