mirror of
https://github.com/samba-team/samba.git
synced 2024-12-23 17:34:34 +03:00
param: use lp[cfg]_max_print_jobs() in lp[cfg]_maxprintjobs()
Signed-off-by: Michael Adam <obnox@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org>
This commit is contained in:
parent
6fdffc826d
commit
c377f63026
@ -3089,7 +3089,8 @@ const char *lpcfg_printername(struct loadparm_service *service, struct loadparm_
|
||||
*/
|
||||
int lpcfg_maxprintjobs(struct loadparm_service *service, struct loadparm_service *sDefault)
|
||||
{
|
||||
int maxjobs = (service != NULL) ? service->max_print_jobs : sDefault->max_print_jobs;
|
||||
int maxjobs = lpcfg_max_print_jobs(service, sDefault);
|
||||
|
||||
if (maxjobs <= 0 || maxjobs >= PRINT_MAX_JOBID)
|
||||
maxjobs = PRINT_MAX_JOBID - 1;
|
||||
|
||||
|
@ -4143,7 +4143,8 @@ void lp_set_logfile(const char *name)
|
||||
|
||||
int lp_maxprintjobs(int snum)
|
||||
{
|
||||
int maxjobs = LP_SNUM_OK(snum) ? ServicePtrs[snum]->max_print_jobs : sDefault.max_print_jobs;
|
||||
int maxjobs = lp_max_print_jobs(snum);
|
||||
|
||||
if (maxjobs <= 0 || maxjobs >= PRINT_MAX_JOBID)
|
||||
maxjobs = PRINT_MAX_JOBID - 1;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user