Lines Matching refs:NULL

42 	if (tmp != NULL) {
46 if (f != NULL)
48 if (tmp->attributes != NULL)
59 if (printers != NULL) {
62 for (i = 0; printers[i] != NULL; i++)
74 papi_printer_t *svc_printers = NULL;
77 if ((svc == NULL) || (printers == NULL))
85 if (f != NULL)
96 if ((result == PAPI_OK) && (svc_printers != NULL)) {
99 *printers = NULL;
100 for (i = 0; svc_printers[i] != NULL; i++) {
101 printer_t *p = NULL;
103 if ((p = calloc(1, sizeof (*p))) == NULL)
121 papi_service_t p_svc = NULL;
122 papi_printer_t printer = NULL;
123 char *psm = NULL;
124 char *uri = NULL;
127 papiAttributeListGetString(p->attributes, NULL,
129 papiAttributeListGetString(p->attributes, NULL, "printer-name", &uri);
130 papiAttributeListGetString(p->attributes, NULL, "printer-uri-supported",
141 result = papiPrinterQuery(p_svc, uri, requested_attrs, NULL, &printer);
160 if (requested == NULL) /* we want every possible attribute */
163 for (i = 0; requested[i] != NULL; i++)
164 if (papiAttributeListFind(list, requested[i]) == NULL)
178 if ((svc == NULL) || (printers == NULL))
182 setprinterentry(0, NULL);
183 while ((attrs = getprinterentry(NULL)) != NULL) {
184 printer_t *p = NULL;
186 if ((p = calloc(1, sizeof (*p))) == NULL)
194 if ((printers != NULL) && (*printers != NULL)) {
198 for (i = 0; (*printers)[i] != NULL; i++) {
216 papi_printer_t *svc_printers = NULL;
219 if ((svc == NULL) || (printers == NULL))
222 if (svc->so_handle != NULL) /* connected, use the print svc */
238 printer_t *p = NULL;
241 if ((svc == NULL) || (name == NULL) || (printer == NULL))
247 if ((*printer = p = calloc(1, sizeof (*p))) == NULL)
250 if ((svc->name != NULL) && (svc->svc_handle != NULL) &&
251 (svc->uri != NULL)) {
254 if (f != NULL)
258 setprinterentry(0, NULL);
259 p->attributes = getprinterbyname(name, NULL);
260 if (p->attributes == NULL)
277 if ((svc == NULL) || (name == NULL))
284 if (f != NULL)
298 if ((svc == NULL) || (name == NULL))
305 if (f != NULL)
346 printer_t *p = NULL;
349 if ((svc == NULL) || (name == NULL) || (attributes == NULL))
355 if ((*printer = p = calloc(1, sizeof (*p))) == NULL)
360 if (f != NULL)
391 if ((svc == NULL) || (name == NULL))
398 if (f != NULL)
409 papi_job_t *svc_jobs = NULL;
412 if ((svc == NULL) || (name == NULL))
419 if (f != NULL)
429 if ((result == PAPI_OK) && (svc_jobs != NULL) && (jobs != NULL)) {
432 *jobs = NULL;
433 for (i = 0; svc_jobs[i] != NULL; i++) {
434 job_t *j = NULL;
436 if ((j = calloc(1, sizeof (*j))) == NULL)
455 papi_job_t *svc_jobs = NULL;
458 if ((svc == NULL) || (name == NULL) || (jobs == NULL))
465 if (f != NULL)
476 if ((result == PAPI_OK) && (svc_jobs != NULL)) {
479 *jobs = NULL;
480 for (i = 0; svc_jobs[i] != NULL; i++) {
481 job_t *j = NULL;
483 if ((j = calloc(1, sizeof (*j))) == NULL)
499 papi_attribute_t **result = NULL;
502 if ((p != NULL) && (p->printer != NULL)) {
507 if (f != NULL)