From: Danny Al-Gaaf Date: Tue, 2 Sep 2014 11:42:49 +0000 (+0200) Subject: ErasureCodeLrc.cc: fix -Wmaybe-uninitialized compiler warning X-Git-Tag: v0.86~135^2~18 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=a754ce517b682a04a6a27410b2e94df78710f0b0;p=ceph.git ErasureCodeLrc.cc: fix -Wmaybe-uninitialized compiler warning Init 'n' with 0 to prevent uninitialized integer. Signed-off-by: Danny Al-Gaaf --- diff --git a/src/erasure-code/lrc/ErasureCodeLrc.cc b/src/erasure-code/lrc/ErasureCodeLrc.cc index caa78960504e..249f9f7a5ac0 100644 --- a/src/erasure-code/lrc/ErasureCodeLrc.cc +++ b/src/erasure-code/lrc/ErasureCodeLrc.cc @@ -443,7 +443,7 @@ int ErasureCodeLrc::parse_ruleset_step(string description_string, json_spirit::write(description, json_string); string op; string type; - int n; + int n = 0; int position = 0; for (vector::iterator i = description.begin(); i != description.end();