diff options
author | Günther Deschner <gd@samba.org> | 2004-08-25 12:31:00 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 10:52:29 -0500 |
commit | b4ec659c76933fa9fe127460e6d1a7fa4fc80656 (patch) | |
tree | 6f659f9015d79db7f72919565a85a5b1481736b8 | |
parent | 77cc4121cf0a31a6594bccd1f86351aee785eb96 (diff) | |
download | samba-b4ec659c76933fa9fe127460e6d1a7fa4fc80656.tar.gz samba-b4ec659c76933fa9fe127460e6d1a7fa4fc80656.tar.bz2 samba-b4ec659c76933fa9fe127460e6d1a7fa4fc80656.zip |
r2067: Prevent nameless $LIBDIR/printing/.tdb from beeing created.
I've seen these on several sites now without knowing how they could get
created.
Guenther
(This used to be commit 531a23d1d22a9951cce5f657df46bd27840eac3d)
-rw-r--r-- | source3/printing/printing_db.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/source3/printing/printing_db.c b/source3/printing/printing_db.c index 9efb3e8ead..e13c0ac888 100644 --- a/source3/printing/printing_db.c +++ b/source3/printing/printing_db.c @@ -37,6 +37,9 @@ struct tdb_print_db *get_print_db_byname(const char *printername) pstring printdb_path; BOOL done_become_root = False; + if (printername == NULL) + return NULL; + for (p = print_db_head, last_entry = print_db_head; p; p = p->next) { /* Ensure the list terminates... JRA. */ SMB_ASSERT(p->next != print_db_head); |