1
0
mirror of https://github.com/samba-team/samba.git synced 2025-08-29 13:49:30 +03:00

don't allow both add and delete user to be set at the same time

(This used to be commit 9db84de46a)
This commit is contained in:
Herb Lewis
2001-04-24 16:44:28 +00:00
parent a4ab60a616
commit 57007050da

View File

@ -319,10 +319,13 @@ static int process_root(int argc, char *argv[])
argv += optind;
/*
* Ensure both add/delete user are not set
* Ensure add/delete user and either remote machine or join domain are
* not both set.
*/
if((local_flags & (LOCAL_ADD_USER|LOCAL_DELETE_USER)) && ((remote_machine != NULL) || joining_domain)) {
if(((local__flags & (LOCAL_ADD_USER|LOCAL_DELETE_USER)) == (LOCAL_ADD_USER|LOCAL_DELETE_USER)) ||
((local_flags & (LOCAL_ADD_USER|LOCAL_DELETE_USER)) &&
((remote_machine != NULL) || joining_domain))) {
usage();
}