| 381 | */ |
| 382 | |
| 383 | int /* O - 1 if there is a conflict, 0 if none, -1 on error */ |
| 384 | cupsCopyDestConflicts( |
| 385 | http_t *http, /* I - Connection to destination */ |
| 386 | cups_dest_t *dest, /* I - Destination */ |
| 387 | cups_dinfo_t *dinfo, /* I - Destination information */ |
| 388 | int num_options, /* I - Number of current options */ |
| 389 | cups_option_t *options, /* I - Current options */ |
| 390 | const char *new_option, /* I - New option */ |
| 391 | const char *new_value, /* I - New value */ |
| 392 | int *num_conflicts, /* O - Number of conflicting options */ |
| 393 | cups_option_t **conflicts, /* O - Conflicting options */ |
| 394 | int *num_resolved, /* O - Number of options to resolve */ |
| 395 | cups_option_t **resolved) /* O - Resolved options */ |
| 396 | { |
| 397 | int i, /* Looping var */ |
| 398 | have_conflicts = 0, /* Do we have conflicts? */ |
| 399 | changed, /* Did we change something? */ |
| 400 | tries, /* Number of tries for resolution */ |
| 401 | num_myconf = 0, /* My number of conflicting options */ |
| 402 | num_myres = 0; /* My number of resolved options */ |
| 403 | cups_option_t *myconf = NULL, /* My conflicting options */ |
| 404 | *myres = NULL, /* My resolved options */ |
| 405 | *myoption, /* My current option */ |
| 406 | *option; /* Current option */ |
| 407 | cups_array_t *active = NULL, /* Active conflicts */ |
| 408 | *pass = NULL, /* Resolvers for this pass */ |
| 409 | *resolvers = NULL, /* Resolvers we have used */ |
| 410 | *test; /* Test array for conflicts */ |
| 411 | _cups_dconstres_t *c, /* Current constraint */ |
| 412 | *r; /* Current resolver */ |
| 413 | ipp_attribute_t *attr; /* Current attribute */ |
| 414 | char value[2048]; /* Current attribute value as string */ |
| 415 | const char *myvalue; /* Current value of an option */ |
| 416 | |
| 417 | |
| 418 | /* |
| 419 | * Clear returned values... |
| 420 | */ |
| 421 | |
| 422 | if (num_conflicts) |
| 423 | *num_conflicts = 0; |
| 424 | |
| 425 | if (conflicts) |
| 426 | *conflicts = NULL; |
| 427 | |
| 428 | if (num_resolved) |
| 429 | *num_resolved = 0; |
| 430 | |
| 431 | if (resolved) |
| 432 | *resolved = NULL; |
| 433 | |
| 434 | /* |
| 435 | * Get the default connection as needed... |
| 436 | */ |
| 437 | |
| 438 | if (!http) |
| 439 | http = _cupsConnect(); |
| 440 |
nothing calls this directly
no test coverage detected