| 1338 | */ |
| 1339 | |
| 1340 | int /* O - Number of destinations */ |
| 1341 | _cupsGetDests(http_t *http, /* I - Connection to server or |
| 1342 | * @code CUPS_HTTP_DEFAULT@ */ |
| 1343 | ipp_op_t op, /* I - IPP operation */ |
| 1344 | const char *name, /* I - Name of destination */ |
| 1345 | cups_dest_t **dests, /* IO - Destinations */ |
| 1346 | cups_ptype_t type, /* I - Printer type bits */ |
| 1347 | cups_ptype_t mask) /* I - Printer type mask */ |
| 1348 | { |
| 1349 | int num_dests = 0; /* Number of destinations */ |
| 1350 | cups_dest_t *dest; /* Current destination */ |
| 1351 | ipp_t *request, /* IPP Request */ |
| 1352 | *response; /* IPP Response */ |
| 1353 | ipp_attribute_t *attr; /* Current attribute */ |
| 1354 | const char *printer_name; /* printer-name attribute */ |
| 1355 | char uri[1024]; /* printer-uri value */ |
| 1356 | int num_options; /* Number of options */ |
| 1357 | cups_option_t *options; /* Options */ |
| 1358 | #ifdef __APPLE__ |
| 1359 | char media_default[41]; /* Default paper size */ |
| 1360 | #endif /* __APPLE__ */ |
| 1361 | char optname[1024], /* Option name */ |
| 1362 | value[2048], /* Option value */ |
| 1363 | *ptr; /* Pointer into name/value */ |
| 1364 | static const char * const pattrs[] = /* Attributes we're interested in */ |
| 1365 | { |
| 1366 | "auth-info-required", |
| 1367 | "device-uri", |
| 1368 | "job-sheets-default", |
| 1369 | "marker-change-time", |
| 1370 | "marker-colors", |
| 1371 | "marker-high-levels", |
| 1372 | "marker-levels", |
| 1373 | "marker-low-levels", |
| 1374 | "marker-message", |
| 1375 | "marker-names", |
| 1376 | "marker-types", |
| 1377 | #ifdef __APPLE__ |
| 1378 | "media-supported", |
| 1379 | #endif /* __APPLE__ */ |
| 1380 | "printer-commands", |
| 1381 | "printer-defaults", |
| 1382 | "printer-info", |
| 1383 | "printer-is-accepting-jobs", |
| 1384 | "printer-is-shared", |
| 1385 | "printer-is-temporary", |
| 1386 | "printer-location", |
| 1387 | "printer-make-and-model", |
| 1388 | "printer-mandatory-job-attributes", |
| 1389 | "printer-name", |
| 1390 | "printer-state", |
| 1391 | "printer-state-change-time", |
| 1392 | "printer-state-reasons", |
| 1393 | "printer-type", |
| 1394 | "printer-uri-supported" |
| 1395 | }; |
| 1396 | |
| 1397 |
no test coverage detected