1
0
mirror of https://github.com/samba-team/samba.git synced 2025-01-04 05:18:06 +03:00
Commit Graph

485 Commits

Author SHA1 Message Date
Gerald Carter
f96f82da05 removing printing = SOFTQ since no one knows what it is
(This used to be commit 7daf5f0042)
2003-04-29 05:30:42 +00:00
Jeremy Allison
c057f9faff Limit the number of outstanding print notify messages for a process to
1000.
Jeremy.
(This used to be commit aabaac05c6)
2003-04-23 00:19:16 +00:00
Jeremy Allison
161017758e Fix mem leak. Spotted by tpot (thanks Tim).
Jeremy.
(This used to be commit adeac265a0)
2003-04-16 08:46:36 +00:00
Jeremy Allison
ac65d89070 Ensure we're not filtering our essential delete messages.
Added jobid debug when unpacking message.
Jeremy.
(This used to be commit 8bab6e3206)
2003-04-10 18:43:00 +00:00
Jeremy Allison
667e6d8279 Ensure print queue array is zeroed out before returning.
Jeremy.
(This used to be commit 337cac7810)
2003-04-09 00:00:50 +00:00
Jeremy Allison
b1b9adebb0 Fix the new storage code to correctly convert from system queue info to
pjob info. Ensure we retrieve more than one job from the storage code.
Jeremy.
(This used to be commit 5dc3150ff3)
2003-04-04 01:02:50 +00:00
Jeremy Allison
f6f96c2966 Subtle changes to message handling after ENUMJOBS.
Jeremy.
(This used to be commit 48f3bf0ea5)
2003-04-02 02:26:01 +00:00
Andrew Bartlett
1e4aaa5a72 Fix a botched merge from appliance-head...
We have an extra NULL here, which is (if I understand correctly) related
to a optional 'charset conversion' function.

In any case, as this is a variable args length function, the compiler
didn't pick it up.

Would it be possible to change applicance_head (or even HEAD) in such
a way that this extra arg would cause a warning?

Finding this by testing is getting painful...

Andrew Bartlett
(This used to be commit b4e52d90f8)
2003-03-31 08:14:37 +00:00
Jeremy Allison
4d7388641a Fix extra NULL arg added during app-head merge.
Jeremy.
(This used to be commit 4868633bc8)
2003-03-26 19:31:44 +00:00
Jeremy Allison
522cc6781f Merge of new appliance-head scalable printing fixes.
Jeremy.
(This used to be commit 301f17df51)
2003-03-21 22:00:19 +00:00
Jeremy Allison
c8eed69be0 lib/messages.c: Check return from chainlock before modifying message queue.
Apply the job returned limit across all requests for job queues.
Jeremy.
(This used to be commit dee1326a1d)
2003-03-20 00:51:41 +00:00
Gerald Carter
26b1ed7cc0 add #define for the max device name length in a DEVICEMODE
(This used to be commit 21ec2b6ba3)
2003-03-06 16:06:12 +00:00
Jeremy Allison
1cdafbf17e Writable string const fixes.
Jeremy.
(This used to be commit 60b0cfc8a5)
2003-03-05 01:30:26 +00:00
Andrew Bartlett
c502756113 Fix another 'off by one' bug with safe_strcpy(). It is unclear if the intent
was to limit the string to 31 or 32 characters (excluding the null term), so
I've assumed for now that 32 is fine, as this matches current behaviour (well, current behaviour would crash, but anyway...)

Jerry:  Can you look at this for me?

Andrew Bartlett
(This used to be commit 6c43327ea2)
2003-03-04 09:33:34 +00:00
Jeremy Allison
728da472c2 Ensure added jobs increment total_jobs.
Jeremy.
(This used to be commit d29c6853dd)
2003-03-01 00:48:09 +00:00
Gerald Carter
7c7d796b6d Progress on CR 601
cache the printer_info_2 with the open printer handle.
cache is invalidated on a mod_a_printer() call **on that smbd**.

Yes, this means that the window for admins to step on each other
from different clients just got larger, but since handles a generally
short lived this is probably ok.
(This used to be commit 33c7b75225)
2003-02-25 20:51:23 +00:00
Jeremy Allison
e7b5d059c2 Bit of a hack job to prevent smbprn.XXX jobs appearing in the queue if the
jobid is below the UNIX_JOB_START number.
Jeremy.
(This used to be commit e8a9bf67cb)
2003-02-19 01:38:12 +00:00
Andrew Bartlett
cc0202884b This patch fixes one of my longest-standing pet hates with Samba :-).
When we look see if a user is in a list, and we try to 'expand' an @group, we
should lookup the user's own list of groups, rather than looking for all the
members of a group.

I'm sure this will fix some nasty performance issues, particularly on large
domains etc.  In particular, this avoids contacting winbind at all, if the
group is not a winbind group.

(This caused a deadlock on my winbind-on-PDC setup).

The groups list always includes the user's primary group, as per the
getgrouplist manpage, and my recent changes to our implementation.

Andrew Bartlett
(This used to be commit 9be21976f7)
2003-02-17 12:27:34 +00:00
Gerald Carter
a703d55cd7 * set PRINTER_ATTRIBUTE_RAW_ONLY; CR 1736
* never save a pointer to an automatic variable (they go away)
  implement a deep copy for SPOOLSS_NOTIFY_MSG to correct
  messages being sent that have junk for strings;
  fix in response to changes for CR 1504
(This used to be commit 043b9dff22)
2003-02-15 23:36:18 +00:00
Gerald Carter
4f6c2ab895 off by one bug in string length; CR 1159
(This used to be commit 4b5b0bcd90)
2003-02-14 22:24:49 +00:00
Andrew Bartlett
ce7db9bdcc Prevent NULL-pointer induced segfaults.
Is tdb_pack in appliance_head different for some reason?

Andrew Bartlett
(This used to be commit 9deb14a2e6)
2003-02-12 06:38:18 +00:00
Andrew Bartlett
a9d598d6bb Failure to find a CUPS printer, when auto-adding printers is not a level 0 error.
Andrew Bartlett
(This used to be commit 79650e08c9)
2003-02-10 09:18:04 +00:00
Jeremy Allison
d05322efce Ensure we return NOSPACE if we can't fast allocate a print job.
Jeremy.
(This used to be commit 9cd29f2bac)
2003-02-08 01:04:26 +00:00
Jeremy Allison
68fdf96637 Collapse duplicate messages before sending.
Jeremy.
(This used to be commit 203959f1c2)
2003-02-05 23:03:47 +00:00
Gerald Carter
9a42f660fb CUPS patch to log client name
(This used to be commit 364a4de6df)
2003-02-05 06:37:54 +00:00
Jeremy Allison
d62f32ceeb Hold the lock for a much shorter time when allocating a new jobid.
Jeremy.
(This used to be commit 0b5a0fec82)
2003-02-04 23:52:46 +00:00
Jeremy Allison
bfcdd6eed3 Up the hash table size for printing tdb.c
Jeremy.
(This used to be commit 5f13d6b4a0)
2003-02-04 23:43:21 +00:00
Jeremy Allison
349c83f243 Ensure we only ever set fsp->conn in one place.
Jeremy.
(This used to be commit 2110901b38)
2003-02-04 01:43:11 +00:00
Jeremy Allison
b102e79e75 Add 3 second timeout when terminating server and sending print notify
messages. Stops build-up of large numbers of smbd's waiting to terminate
on large print throughput.
Jeremy.
(This used to be commit 4ae130bfa8)
2003-01-30 23:55:13 +00:00
Jeremy Allison
bcf6fae786 More scalable print tdb fixes.
Jeremy.
(This used to be commit fa8647eb20)
2003-01-30 23:27:16 +00:00
Gerald Carter
9c50a316f5 CUPS-PRINTER_CLASS patch from Michael Sweet
(This used to be commit d74d4fe0b0)
2003-01-28 01:58:51 +00:00
Andrew Bartlett
0a8b4417bc Fix warnings by getting the function into a shape the autoprototyper will
read, and add a static.

Andrew Bartlett
(This used to be commit 919889de78)
2003-01-15 05:56:12 +00:00
Andrew Bartlett
10abfb3f87 Crash fixes:
- fix a crash when a second NTLMSSP session tried to free the first
 - fix a crash due to some NULL pointers in the Add Printer Wizard (or read
   printer code too it appears).  As far as I can tell it's just that the
   GUID just might not exist.

Andrew Bartlett
(This used to be commit 51b1413056)
2003-01-15 05:55:22 +00:00
Andrew Bartlett
1fdaca3342 The last of the fstring/pstring mixups, and an extra 'static'.
(This used to be commit b328b67fd8)
2003-01-14 06:46:14 +00:00
Gerald Carter
47873e781d [merge] make sure to updatre print queue cache during timeout_processing() to send notify events; CR 1491
(This used to be commit 142c5029c7)
2003-01-11 02:29:23 +00:00
Jeremy Allison
d2377ad556 Fix lpq_cache time check (missed from yesterday).
Jeremy.
(This used to be commit 21c8acd25a)
2003-01-10 19:59:18 +00:00
Andrew Bartlett
6d66fb308a BIG patch...
This patch makes Samba compile cleanly with -Wwrite-strings.
 - That is, all string literals are marked as 'const'.  These strings are
always read only, this just marks them as such for passing to other functions.

What is most supprising is that I didn't need to change more than a few lines of code (all
in 'net', which got a small cleanup of net.h and extern variables).  The rest
is just adding a lot of 'const'.

As far as I can tell, I have not added any new warnings - apart from making all
of tdbutil.c's function const (so they warn for adding that const string to
struct).

Andrew Bartlett
(This used to be commit 92a777d0ea)
2003-01-02 09:07:17 +00:00
Jeremy Allison
7f23546730 Forward port the change to talloc_init() to make all talloc contexts
named. Ensure we can query them.
Jeremy.
(This used to be commit 842e08e52a)
2002-12-20 20:23:06 +00:00
Jim McDonough
5f9348d4fc Store printer guid in the dsspooler registry key so we don't have to
query the directory server every time someone asks
(This used to be commit f0fc4e30f6)
2002-12-13 21:54:09 +00:00
Jim McDonough
bfd8043a40 More printer publishing code.
- Add published attribute to info2, needed for win clients to work properly
- Return proper info on getprinter 7

This means you can now look at the sharing tab of a printer and get correct
info about whether it is published or not, and change it.
(This used to be commit adda04379e)
2002-12-13 18:56:48 +00:00
Jeremy Allison
1815dad960 Fix debugs for rap mapping. Delete job on map fail.
Jeremy.
(This used to be commit 631d606698)
2002-12-05 22:32:25 +00:00
Jim McDonough
90d9cf973e More printer data to publish
(This used to be commit 82f3a786bf)
2002-12-05 19:13:20 +00:00
Jeremy Allison
76e685e628 The element in fsp->print_job should be a RAP jobid, not a uint32 RPC
jobid. This was causing Win9x client "set name" calls to fail.
Still need one cleanup fix to finish.
Jeremy.
(This used to be commit 15f0bad1fc)
2002-12-05 03:59:56 +00:00
Jim McDonough
6d66efe6c2 More attributes to publish. All DsSpooler attributes except REG_MULTI_SZ ones should be published now.
(This used to be commit 4fc602fd7d)
2002-12-04 21:30:52 +00:00
Jeremy Allison
cf7f1d5de0 Janitor for tpot yet again... Merging in memory leak fix.
Jeremy.
(This used to be commit a2ab78d68d)
2002-12-04 21:28:23 +00:00
Jim McDonough
2dd0e949d0 Automatic printer publishing when using APW or choosing 'list in the directory' in printer settings. Currently very little is published, and you cannot unpublish because of a bug in win2k clients.
(This used to be commit bbd7c8071a)
2002-12-04 17:28:51 +00:00
Gerald Carter
585e8a8c02 [print notify fixes from APP_HEAD]
* fixing change notify on print server handle
 * adding change notify support into smbcontrol for sending comment
   changes, etc...

All part of CR 1159/1160
(This used to be commit 256d8c27cd)
2002-11-26 00:01:56 +00:00
Andrew Bartlett
94596400e3 No need to #include smb.h, when we already #include include.h
(This used to be commit b3049bb0d0)
2002-11-24 08:37:02 +00:00
Jeremy Allison
f023d6129b Lots of fixes for error paths where tdb_fetch() data need freeing.
Found via a post from Arcady Chernyak <Arcady.Chernyak@efi.com>.
Jeremy.
(This used to be commit 19f86f1f72)
2002-11-23 02:52:38 +00:00
Jeremy Allison
250c980119 Removed global_myworkgroup, global_myname, global_myscope. Added liberal
dashes of const. This is a rather large check-in, some things may break.
It does compile though :-).
Jeremy.
(This used to be commit 82b8f749a3)
2002-11-12 23:15:52 +00:00