1
0
mirror of https://gitlab.gnome.org/GNOME/libxml2.git synced 2025-07-30 22:43:14 +03:00

Remove useless comparisons

Found by lgtm.com
This commit is contained in:
Nick Wellnhofer
2020-01-02 14:14:48 +01:00
parent c9faa29259
commit 9bd7abfba4
5 changed files with 114 additions and 122 deletions

View File

@ -6055,7 +6055,7 @@ xmlAutomataNewOnceTrans2(xmlAutomataPtr am, xmlAutomataStatePtr from,
return(NULL);
if (min < 1)
return(NULL);
if ((max < min) || (max < 1))
if (max < min)
return(NULL);
atom = xmlRegNewAtom(am, XML_REGEXP_STRING);
if (atom == NULL)
@ -6134,7 +6134,7 @@ xmlAutomataNewOnceTrans(xmlAutomataPtr am, xmlAutomataStatePtr from,
return(NULL);
if (min < 1)
return(NULL);
if ((max < min) || (max < 1))
if (max < min)
return(NULL);
atom = xmlRegNewAtom(am, XML_REGEXP_STRING);
if (atom == NULL)