fdo#39440 eliminate redundant condition

addresses the following cppcheck "redundantCondition"
warning:
"Redundant condition: If n > 0, the comparison
n != -1 is always true."

Change-Id: I879b1e3a07b56560dd635a399b6079f9bd2f9590
Reviewed-on: https://gerrit.libreoffice.org/13461
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
diff --git a/sc/source/core/tool/address.cxx b/sc/source/core/tool/address.cxx
index 1efcac7..c6deace 100644
--- a/sc/source/core/tool/address.cxx
+++ b/sc/source/core/tool/address.cxx
@@ -1106,7 +1106,7 @@ static sal_uInt16 lcl_ScAddress_Parse_OOo( const sal_Unicode* p, ScDocument* pDo
            // Specified table name is not found in this document.  Assume this is an external document.
            aDocName = aTab;
            sal_Int32 n = aDocName.lastIndexOf('.');
            if (n != -1 && n > 0)
            if (n > 0)
            {
                // Extension found.  Strip it.
                aTab = aTab.replaceAt(n, 1, "");