Fix version comparision bug

This commit is contained in:
Glenn L McGrath 2001-08-15 11:25:01 +00:00
parent b6ec78161d
commit bac490fe53
2 changed files with 2 additions and 2 deletions

View File

@ -217,7 +217,7 @@ int version_compare_part(const char *version1, const char *version2)
if (version1 == NULL) { if (version1 == NULL) {
version1 = xstrdup(""); version1 = xstrdup("");
} }
if (version2 != NULL) { if (version2 == NULL) {
version2 = xstrdup(""); version2 = xstrdup("");
} }
upstream_len1 = strlen(version1); upstream_len1 = strlen(version1);

2
dpkg.c
View File

@ -217,7 +217,7 @@ int version_compare_part(const char *version1, const char *version2)
if (version1 == NULL) { if (version1 == NULL) {
version1 = xstrdup(""); version1 = xstrdup("");
} }
if (version2 != NULL) { if (version2 == NULL) {
version2 = xstrdup(""); version2 = xstrdup("");
} }
upstream_len1 = strlen(version1); upstream_len1 = strlen(version1);