Merge.
authorTim Potter <tpot@samba.org>
Mon, 14 Aug 2000 21:27:54 +0000 (21:27 +0000)
committerTim Potter <tpot@samba.org>
Mon, 14 Aug 2000 21:27:54 +0000 (21:27 +0000)
(This used to be commit 604f6a34effb8aeed7701345a4219749a6a97892)

testsuite/printing/psec.c

index e3490de7598e4df220021530ccd3a25b2fe838cb..28c4ee0ca51709f45c9a152598bb9d82382a383a 100644 (file)
@@ -167,7 +167,7 @@ int psec_getsec(char *printer)
 
        /* Open tdb for reading */
 
-       slprintf(tdb_path, "%s/ntdrivers.tdb", LOCKDIR);
+       slprintf(tdb_path, sizeof(tdb_path) - 1, "%s/ntdrivers.tdb", LOCKDIR);
        tdb = tdb_open(tdb_path, 0, 0, O_RDONLY, 0600);
 
        if (!tdb) {
@@ -264,7 +264,7 @@ int psec_setsec(char *printer)
 
        /* Open tdb for reading */
 
-       slprintf(tdb_path, "%s/ntdrivers.tdb", LOCKDIR);
+       slprintf(tdb_path, sizeof(tdb_path) - 1, "%s/ntdrivers.tdb", LOCKDIR);
        tdb = tdb_open(tdb_path, 0, 0, O_RDWR, 0600);
 
        if (!tdb) {