fixed a off by one bug in ntforms read from the database
authorAndrew Tridgell <tridge@samba.org>
Mon, 5 Jun 2000 11:45:56 +0000 (11:45 +0000)
committerAndrew Tridgell <tridge@samba.org>
Mon, 5 Jun 2000 11:45:56 +0000 (11:45 +0000)
source/printing/nt_printing.c

index 1b38c6e72c9de072665852a4f101a9a0bfe719f4..0f778841129c48c403753a1aa0c01fc8c32bbbdf 100644 (file)
@@ -78,7 +78,7 @@ int get_ntforms(nt_forms_struct **list)
                dbuf = tdb_fetch(tdb, kbuf);
                if (!dbuf.dptr) continue;
 
-               fstrcpy(form.name, kbuf.dptr+strlen(FORMS_PREFIX));
+               fstrcpy(form.name, kbuf.dptr+strlen(FORMS_PREFIX)+1);
                ret = tdb_unpack(dbuf.dptr, dbuf.dsize, "ddddddd",
                                 &form.flag, &form.width, &form.length, &form.left,
                                 &form.top, &form.right, &form.bottom);