diff options
author | Stefan Metzmacher <metze@samba.org> | 2005-06-07 14:31:45 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 13:17:47 -0500 |
commit | 30da4d8d93cbfc0062a6c97c2b8255670615405c (patch) | |
tree | dc5ced5b7fd22ad80717ff16eb7059954cb9f99c /source4/torture/rpc | |
parent | 501986ab4e5483b378c875795c95d077db59b77d (diff) | |
download | samba-30da4d8d93cbfc0062a6c97c2b8255670615405c.tar.gz samba-30da4d8d93cbfc0062a6c97c2b8255670615405c.tar.bz2 samba-30da4d8d93cbfc0062a6c97c2b8255670615405c.zip |
r7369: allow no entries returned by Enum*()
metze
(This used to be commit 3778da9d17778cb215ac08e1dcd6ad8c0fa13dfd)
Diffstat (limited to 'source4/torture/rpc')
-rw-r--r-- | source4/torture/rpc/spoolss.c | 25 |
1 files changed, 20 insertions, 5 deletions
diff --git a/source4/torture/rpc/spoolss.c b/source4/torture/rpc/spoolss.c index 0ea74c7e56..5d9390ab59 100644 --- a/source4/torture/rpc/spoolss.c +++ b/source4/torture/rpc/spoolss.c @@ -149,7 +149,10 @@ static BOOL test_EnumPorts(struct test_spoolss_context *ctx) ret = False; continue; } - + if (W_ERROR_IS_OK(r.out.result)) { + /* TODO: do some more checks here */ + continue; + } if (!W_ERROR_EQUAL(r.out.result, WERR_INSUFFICIENT_BUFFER)) { printf("EnumPorts unexspected return code %s, should be WERR_INSUFFICIENT_BUFFER\n", win_errstr(r.out.result)); @@ -239,7 +242,10 @@ static BOOL test_EnumPrinterDrivers(struct test_spoolss_context *ctx) ret = False; continue; } - + if (W_ERROR_IS_OK(r.out.result)) { + /* TODO: do some more checks here */ + continue; + } if (!W_ERROR_EQUAL(r.out.result, WERR_INSUFFICIENT_BUFFER)) { printf("EnumPrinterDrivers unexspected return code %s, should be WERR_INSUFFICIENT_BUFFER\n", win_errstr(r.out.result)); @@ -372,7 +378,10 @@ static BOOL test_EnumMonitors(struct test_spoolss_context *ctx) ret = False; continue; } - + if (W_ERROR_IS_OK(r.out.result)) { + /* TODO: do some more checks here */ + continue; + } if (!W_ERROR_EQUAL(r.out.result, WERR_INSUFFICIENT_BUFFER)) { printf("EnumMonitors unexspected return code %s, should be WERR_INSUFFICIENT_BUFFER\n", win_errstr(r.out.result)); @@ -462,7 +471,10 @@ static BOOL test_EnumPrintProcessors(struct test_spoolss_context *ctx) ret = False; continue; } - + if (W_ERROR_IS_OK(r.out.result)) { + /* TODO: do some more checks here */ + continue; + } if (!W_ERROR_EQUAL(r.out.result, WERR_INSUFFICIENT_BUFFER)) { printf("EnumPrintProcessors unexspected return code %s, should be WERR_INSUFFICIENT_BUFFER\n", win_errstr(r.out.result)); @@ -550,7 +562,10 @@ static BOOL test_EnumPrinters(struct test_spoolss_context *ctx) ret = False; continue; } - + if (W_ERROR_IS_OK(r.out.result)) { + /* TODO: do some more checks here */ + continue; + } if (!W_ERROR_EQUAL(r.out.result, WERR_INSUFFICIENT_BUFFER)) { printf("EnumPrinters unexspected return code %s, should be WERR_INSUFFICIENT_BUFFER\n", win_errstr(r.out.result)); |