diff options
author | bmilekic <bmilekic@FreeBSD.org> | 2003-08-01 17:26:41 +0000 |
---|---|---|
committer | bmilekic <bmilekic@FreeBSD.org> | 2003-08-01 17:26:41 +0000 |
commit | 25665981dd793b68604567181e50d307831c96f1 (patch) | |
tree | a5f8a752d52b113384cbd6dbd48966a9520036d0 /usr.sbin | |
parent | e43686a8dce4909587cda7c2b406b65036f62289 (diff) | |
download | FreeBSD-src-25665981dd793b68604567181e50d307831c96f1.zip FreeBSD-src-25665981dd793b68604567181e50d307831c96f1.tar.gz |
Use strncmp() and not strcmp() here to properly match
installed ports.
Submitted by: Harold Gutch <logix@foobar.franken.de>
Diffstat (limited to 'usr.sbin')
-rw-r--r-- | usr.sbin/pkg_install/lib/match.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/usr.sbin/pkg_install/lib/match.c b/usr.sbin/pkg_install/lib/match.c index 5312c27..550993a 100644 --- a/usr.sbin/pkg_install/lib/match.c +++ b/usr.sbin/pkg_install/lib/match.c @@ -212,7 +212,7 @@ matchbyorigin(const char *origin, int *retval) continue; cmd = plist_cmd(tmp + 1, &cp); if (cmd == PLIST_ORIGIN) { - if (strcmp(origin, cp) == 0) + if (strncmp(origin, cp, strlen(origin)) == 0) storeappend(store, installed[i]); break; } |