From: Georg Baum Date: Sat, 10 Oct 2015 19:23:52 +0000 (+0200) Subject: Fix duplicated pointer check X-Git-Tag: 2.2.0alpha1~246 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=60e594a0f73fa50d9b5a75ddbc2f686565dd814b;p=features.git Fix duplicated pointer check Found by cppcheck: (style) Same expression on both sides of '&&'. --- diff --git a/src/lyxfind.cpp b/src/lyxfind.cpp index 2cd05ea4a7..c217281b66 100644 --- a/src/lyxfind.cpp +++ b/src/lyxfind.cpp @@ -1072,7 +1072,7 @@ docstring latexifyFromCursor(DocIterator const & cur, int len) // Retrieve the math environment type, and add '$' or '$[' or others (\begin{equation}) accordingly for (int s = cur.depth() - 1; s >= 0; --s) { CursorSlice const & cs = cur[s]; - if (cs.asInsetMath() && cs.asInsetMath() && cs.asInsetMath()->asHullInset()) { + if (cs.asInsetMath() && cs.asInsetMath()->asHullInset()) { WriteStream ws(ods); cs.asInsetMath()->asHullInset()->header_write(ws); break;