From: Howard Chu Date: Fri, 7 Dec 2012 20:06:30 +0000 (-0800) Subject: ITS#7465 fail if both -a and -s specified X-Git-Tag: OPENLDAP_REL_ENG_2_4_34~90^2~3 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=784757faa91b4570465e7fc6453305324e686a0a;p=openldap ITS#7465 fail if both -a and -s specified --- diff --git a/libraries/liblmdb/mdb_stat.c b/libraries/liblmdb/mdb_stat.c index 4dfcf49645..e9981f6016 100644 --- a/libraries/liblmdb/mdb_stat.c +++ b/libraries/liblmdb/mdb_stat.c @@ -62,6 +62,8 @@ int main(int argc, char *argv[]) while ((i = getopt(argc, argv, "aefns:")) != EOF) { switch(i) { case 'a': + if (subname) + usage(prog); alldbs++; break; case 'e': @@ -74,6 +76,8 @@ int main(int argc, char *argv[]) envflags |= MDB_NOSUBDIR; break; case 's': + if (alldbs) + usage(prog); subname = optarg; break; default: