Lines Matching refs:param

230 	struct spoolss_OpenPrinter *param = arg;  in spoolss_s_OpenPrinter()  local
231 char *name = (char *)param->printer_name; in spoolss_s_OpenPrinter()
236 bzero(&param->handle, sizeof (spoolss_handle_t)); in spoolss_s_OpenPrinter()
237 param->status = ERROR_INVALID_PRINTER_NAME; in spoolss_s_OpenPrinter()
245 bzero(&param->handle, sizeof (spoolss_handle_t)); in spoolss_s_OpenPrinter()
246 param->status = ERROR_NOT_ENOUGH_MEMORY; in spoolss_s_OpenPrinter()
250 bcopy(id, &param->handle, sizeof (spoolss_handle_t)); in spoolss_s_OpenPrinter()
251 param->status = 0; in spoolss_s_OpenPrinter()
259 struct spoolss_StartPagePrinter *param = arg; in spoolss_s_StartPagePrinter() local
261 param->status = ERROR_SUCCESS; in spoolss_s_StartPagePrinter()
270 struct spoolss_EndPagePrinter *param = arg; in spoolss_s_EndPagePrinter() local
272 param->status = ERROR_SUCCESS; in spoolss_s_EndPagePrinter()
285 struct spoolss_StartDocPrinter *param = arg; in spoolss_s_StartDocPrinter() local
286 ndr_hdid_t *id = (ndr_hdid_t *)&param->handle; in spoolss_s_StartDocPrinter()
296 param->status = ERROR_INVALID_HANDLE; in spoolss_s_StartDocPrinter()
300 if ((docinfo = param->dinfo.DocInfoContainer) == NULL) { in spoolss_s_StartDocPrinter()
301 param->status = ERROR_INVALID_PARAMETER; in spoolss_s_StartDocPrinter()
308 param->status = rc; in spoolss_s_StartDocPrinter()
313 param->status = ERROR_NOT_ENOUGH_MEMORY; in spoolss_s_StartDocPrinter()
332 (void) memcpy(&spfile->sd_handle, &param->handle, sizeof (ndr_hdid_t)); in spoolss_s_StartDocPrinter()
345 param->status = ERROR_OPEN_FAILED; in spoolss_s_StartDocPrinter()
363 param->JobId = 46; in spoolss_s_StartDocPrinter()
364 param->status = ERROR_SUCCESS; in spoolss_s_StartDocPrinter()
377 struct spoolss_EndDocPrinter *param = arg; in spoolss_s_EndDocPrinter() local
378 ndr_hdid_t *id = (ndr_hdid_t *)&param->handle; in spoolss_s_EndDocPrinter()
383 param->status = ERROR_INVALID_HANDLE; in spoolss_s_EndDocPrinter()
387 param->status = ERROR_INVALID_HANDLE; in spoolss_s_EndDocPrinter()
398 param->status = ERROR_SUCCESS; in spoolss_s_EndDocPrinter()
407 if (param->status != ERROR_SUCCESS) in spoolss_s_EndDocPrinter()
416 struct spoolss_AbortPrinter *param = arg; in spoolss_s_AbortPrinter() local
418 param->status = ERROR_SUCCESS; in spoolss_s_AbortPrinter()
426 struct spoolss_AbortPrinter *param = arg; in spoolss_s_ResetPrinter() local
428 param->status = ERROR_SUCCESS; in spoolss_s_ResetPrinter()
435 struct spoolss_ClosePrinter *param = arg; in spoolss_s_ClosePrinter() local
436 ndr_hdid_t *id = (ndr_hdid_t *)&param->handle; in spoolss_s_ClosePrinter()
445 bzero(&param->result_handle, sizeof (spoolss_handle_t)); in spoolss_s_ClosePrinter()
446 param->status = ERROR_SUCCESS; in spoolss_s_ClosePrinter()
453 struct spoolss_AddForm *param = arg; in spoolss_s_AddForm() local
454 ndr_hdid_t *id = (ndr_hdid_t *)&param->handle; in spoolss_s_AddForm()
457 bzero(param, sizeof (struct spoolss_AddForm)); in spoolss_s_AddForm()
458 param->status = ERROR_INVALID_HANDLE; in spoolss_s_AddForm()
462 bzero(param, sizeof (struct spoolss_AddForm)); in spoolss_s_AddForm()
463 param->status = ERROR_SUCCESS; in spoolss_s_AddForm()
470 struct spoolss_DeleteForm *param = arg; in spoolss_s_DeleteForm() local
471 ndr_hdid_t *id = (ndr_hdid_t *)&param->handle; in spoolss_s_DeleteForm()
474 bzero(param, sizeof (struct spoolss_DeleteForm)); in spoolss_s_DeleteForm()
475 param->status = ERROR_INVALID_HANDLE; in spoolss_s_DeleteForm()
479 bzero(param, sizeof (struct spoolss_DeleteForm)); in spoolss_s_DeleteForm()
480 param->status = ERROR_SUCCESS; in spoolss_s_DeleteForm()
487 struct spoolss_EnumForms *param = arg; in spoolss_s_EnumForms() local
488 ndr_hdid_t *id = (ndr_hdid_t *)&param->handle; in spoolss_s_EnumForms()
491 bzero(param, sizeof (struct spoolss_EnumForms)); in spoolss_s_EnumForms()
492 param->status = ERROR_INVALID_HANDLE; in spoolss_s_EnumForms()
496 bzero(param, sizeof (struct spoolss_EnumForms)); in spoolss_s_EnumForms()
497 param->status = ERROR_SUCCESS; in spoolss_s_EnumForms()
498 param->needed = 0; in spoolss_s_EnumForms()
506 struct spoolss_AddMonitor *param = arg; in spoolss_s_AddMonitor() local
508 param->status = ERROR_SUCCESS; in spoolss_s_AddMonitor()
516 struct spoolss_DeleteMonitor *param = arg; in spoolss_s_DeleteMonitor() local
518 param->status = ERROR_SUCCESS; in spoolss_s_DeleteMonitor()
526 struct spoolss_DeletePort *param = arg; in spoolss_s_DeletePort() local
528 param->status = ERROR_SUCCESS; in spoolss_s_DeletePort()
536 struct spoolss_AddPortEx *param = arg; in spoolss_s_AddPortEx() local
538 param->status = ERROR_SUCCESS; in spoolss_s_AddPortEx()
546 struct spoolss_SetPort *param = arg; in spoolss_s_SetPort() local
548 param->status = ERROR_SUCCESS; in spoolss_s_SetPort()
556 struct spoolss_EnumJobs *param = arg; in spoolss_s_EnumJobs() local
559 switch (param->level) { in spoolss_s_EnumJobs()
568 param->status = status; in spoolss_s_EnumJobs()
569 param->needed = 0; in spoolss_s_EnumJobs()
570 param->needed2 = 0; in spoolss_s_EnumJobs()
579 struct spoolss_GetJob *param = arg; in spoolss_s_GetJob() local
582 if (param->BufCount == 0) in spoolss_s_GetJob()
583 param->status = ERROR_INSUFFICIENT_BUFFER; in spoolss_s_GetJob()
585 param->status = status; in spoolss_s_GetJob()
586 param->needed = 0; in spoolss_s_GetJob()
595 struct spoolss_ScheduleJob *param = arg; in spoolss_s_ScheduleJob() local
598 param->status = status; in spoolss_s_ScheduleJob()
606 struct spoolss_AddJob *param = arg; in spoolss_s_AddJob() local
608 param->status = ERROR_SUCCESS; in spoolss_s_AddJob()
609 param->needed = 0; in spoolss_s_AddJob()
617 struct spoolss_RFNPCNEX *param = arg; in spoolss_s_rfnpcnex() local
619 param->ppinfo = 0; in spoolss_s_rfnpcnex()
620 param->status = ERROR_SUCCESS; in spoolss_s_rfnpcnex()
630 struct spoolss_WritePrinter *param = arg; in spoolss_s_WritePrinter() local
632 ndr_hdid_t *id = (ndr_hdid_t *)&param->handle; in spoolss_s_WritePrinter()
636 param->written = 0; in spoolss_s_WritePrinter()
637 param->status = ERROR_INVALID_HANDLE; in spoolss_s_WritePrinter()
643 param->written = 0; in spoolss_s_WritePrinter()
644 param->status = ERROR_INVALID_HANDLE; in spoolss_s_WritePrinter()
649 written = write(spfd, param->pBuf, param->BufCount); in spoolss_s_WritePrinter()
650 if (written < param->BufCount) { in spoolss_s_WritePrinter()
652 param->written = 0; in spoolss_s_WritePrinter()
653 param->status = ERROR_CANTWRITE; in spoolss_s_WritePrinter()
657 param->written = written; in spoolss_s_WritePrinter()
658 param->status = ERROR_SUCCESS; in spoolss_s_WritePrinter()
705 struct spoolss_GetPrinterData *param = arg; in spoolss_s_GetPrinterData() local
706 char *name = (char *)param->pValueName; in spoolss_s_GetPrinterData()
725 param->pType = WINREG_DWORD; in spoolss_s_GetPrinterData()
726 param->Needed = sizeof (uint32_t); in spoolss_s_GetPrinterData()
732 if (param->Size < sizeof (uint32_t)) { in spoolss_s_GetPrinterData()
733 param->Size = 0; in spoolss_s_GetPrinterData()
737 if ((param->Buf = NDR_NEW(mxa, uint32_t)) == NULL) { in spoolss_s_GetPrinterData()
748 bcopy(&value, param->Buf, sizeof (uint32_t)); in spoolss_s_GetPrinterData()
749 param->Size = sizeof (uint32_t); in spoolss_s_GetPrinterData()
750 param->status = ERROR_SUCCESS; in spoolss_s_GetPrinterData()
755 param->pType = WINREG_BINARY; in spoolss_s_GetPrinterData()
756 param->Needed = sizeof (smb_version_t); in spoolss_s_GetPrinterData()
758 if (param->Size < sizeof (smb_version_t)) { in spoolss_s_GetPrinterData()
759 param->Size = sizeof (smb_version_t); in spoolss_s_GetPrinterData()
769 param->Buf = (uint8_t *)osversion; in spoolss_s_GetPrinterData()
770 param->status = ERROR_SUCCESS; in spoolss_s_GetPrinterData()
775 param->pType = WINREG_SZ; in spoolss_s_GetPrinterData()
782 param->pType = WINREG_SZ; in spoolss_s_GetPrinterData()
797 param->pType = WINREG_SZ; in spoolss_s_GetPrinterData()
811 bzero(param, sizeof (struct spoolss_GetPrinterData)); in spoolss_s_GetPrinterData()
812 param->Buf = reserved_buf; in spoolss_s_GetPrinterData()
813 param->status = status; in spoolss_s_GetPrinterData()
818 if (param->Size < wcslen) { in spoolss_s_GetPrinterData()
819 param->Needed = wcslen; in spoolss_s_GetPrinterData()
829 param->Buf = (uint8_t *)wcs; in spoolss_s_GetPrinterData()
830 param->Needed = wcslen; in spoolss_s_GetPrinterData()
831 param->status = ERROR_SUCCESS; in spoolss_s_GetPrinterData()
835 param->Size = 0; in spoolss_s_GetPrinterData()
836 param->Buf = reserved_buf; in spoolss_s_GetPrinterData()
837 param->status = ERROR_MORE_DATA; in spoolss_s_GetPrinterData()
858 struct spoolss_GetPrinter *param = arg; in spoolss_s_GetPrinter() local
863 ndr_hdid_t *id = (ndr_hdid_t *)&param->handle; in spoolss_s_GetPrinter()
884 switch (param->switch_value) { in spoolss_s_GetPrinter()
887 param->needed = 460; in spoolss_s_GetPrinter()
890 param->needed = 712; in spoolss_s_GetPrinter()
897 if (param->BufCount < param->needed) { in spoolss_s_GetPrinter()
898 param->BufCount = 0; in spoolss_s_GetPrinter()
899 param->Buf = NULL; in spoolss_s_GetPrinter()
900 param->status = ERROR_INSUFFICIENT_BUFFER; in spoolss_s_GetPrinter()
904 if ((param->Buf = NDR_MALLOC(mxa, param->BufCount)) == NULL) { in spoolss_s_GetPrinter()
909 bzero(param->Buf, param->BufCount); in spoolss_s_GetPrinter()
910 wname = (char *)param->Buf; in spoolss_s_GetPrinter()
911 offset = param->needed; in spoolss_s_GetPrinter()
913 switch (param->switch_value) { in spoolss_s_GetPrinter()
916 pinfo0 = (struct spoolss_GetPrinter0 *)param->Buf; in spoolss_s_GetPrinter()
938 pinfo1 = (struct spoolss_GetPrinter1 *)param->Buf; in spoolss_s_GetPrinter()
947 pinfo2 = (struct spoolss_GetPrinter2 *)param->Buf; in spoolss_s_GetPrinter()
963 devmode2 = (struct spoolss_DeviceMode *)(param->Buf + offset); in spoolss_s_GetPrinter()
975 tmpbuf = (uint8_t *)(param->Buf + offset); in spoolss_s_GetPrinter()
1031 param->status = status; in spoolss_s_GetPrinter()
1036 bzero(param, sizeof (struct spoolss_GetPrinter)); in spoolss_s_GetPrinter()
1037 param->status = status; in spoolss_s_GetPrinter()