MCPcopy Create free account
hub / github.com/OpenPrinting/cups / cups_get_cb

Function cups_get_cb

cups/dest.c:4087–4110  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

4085 */
4086
4087static int /* O - 1 to continue, 0 to stop */
4088cups_get_cb(_cups_getdata_t *data, /* I - Data from cupsGetDests */
4089 unsigned flags, /* I - Enumeration flags */
4090 cups_dest_t *dest) /* I - Destination */
4091{
4092 if (flags & CUPS_DEST_FLAGS_REMOVED)
4093 {
4094 /*
4095 * Remove destination from array...
4096 */
4097
4098 data->num_dests = cupsRemoveDest(dest->name, dest->instance, data->num_dests, &data->dests);
4099 }
4100 else
4101 {
4102 /*
4103 * Add destination to array...
4104 */
4105
4106 data->num_dests = cupsCopyDest(dest, data->num_dests, &data->dests);
4107 }
4108
4109 return (1);
4110}
4111
4112
4113/*

Callers

nothing calls this directly

Calls 2

cupsRemoveDestFunction · 0.85
cupsCopyDestFunction · 0.85

Tested by

no test coverage detected