X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2FIndicesList.cpp;h=52fbbde51e6f0eda0b2a2239b39c11fa5ad09d46;hb=62af7ee772f16f154225d2d0b65d77f4376b6001;hp=e974cebc9da6d059b2bedce9a8ff600c9da00092;hpb=e30f3d76d2bee0011ceaeb5f0cc221156458cbad;p=lyx.git diff --git a/src/IndicesList.cpp b/src/IndicesList.cpp index e974cebc9d..52fbbde51e 100644 --- a/src/IndicesList.cpp +++ b/src/IndicesList.cpp @@ -190,11 +190,11 @@ bool IndicesList::add(docstring const & n, docstring const & s) docstring sc = s.empty() ? trim(lowercase(name.substr(0, 3))) : s; if (findShortcut(sc) != 0) { - int i = 1; - docstring scn = sc + convert(i); + int k = 1; + docstring scn = sc + convert(k); while (findShortcut(scn) != 0) { - ++i; - scn = sc + convert(i); + ++k; + scn = sc + convert(k); } in.setShortcut(scn); } else