Revision 339a475f
b/ui/spice-core.c | ||
---|---|---|
227 | 227 |
add_addr_info(server, (struct sockaddr *)&info->laddr_ext, |
228 | 228 |
info->llen_ext); |
229 | 229 |
} else { |
230 |
fprintf(stderr, "spice: %s, extended address is expected\n",
|
|
231 |
__func__);
|
|
230 |
error_report("spice: %s, extended address is expected",
|
|
231 |
__func__); |
|
232 | 232 |
#endif |
233 | 233 |
add_addr_info(client, &info->paddr, info->plen); |
234 | 234 |
add_addr_info(server, &info->laddr, info->llen); |
... | ... | |
333 | 333 |
if (value != -1) { |
334 | 334 |
return value; |
335 | 335 |
} |
336 |
fprintf(stderr, "spice: invalid %s: %s\n", optname, string);
|
|
336 |
error_report("spice: invalid %s: %s", optname, string);
|
|
337 | 337 |
exit(1); |
338 | 338 |
} |
339 | 339 |
|
... | ... | |
525 | 525 |
rc = spice_server_set_channel_security(spice_server, value, security); |
526 | 526 |
} |
527 | 527 |
if (rc != 0) { |
528 |
fprintf(stderr, "spice: failed to set channel security for %s\n", value);
|
|
528 |
error_report("spice: failed to set channel security for %s", value);
|
|
529 | 529 |
exit(1); |
530 | 530 |
} |
531 | 531 |
return 0; |
... | ... | |
553 | 553 |
port = qemu_opt_get_number(opts, "port", 0); |
554 | 554 |
tls_port = qemu_opt_get_number(opts, "tls-port", 0); |
555 | 555 |
if (!port && !tls_port) { |
556 |
fprintf(stderr, "neither port nor tls-port specified for spice.");
|
|
556 |
error_report("neither port nor tls-port specified for spice");
|
|
557 | 557 |
exit(1); |
558 | 558 |
} |
559 | 559 |
if (port < 0 || port > 65535) { |
560 |
fprintf(stderr, "spice port is out of range");
|
|
560 |
error_report("spice port is out of range");
|
|
561 | 561 |
exit(1); |
562 | 562 |
} |
563 | 563 |
if (tls_port < 0 || tls_port > 65535) { |
564 |
fprintf(stderr, "spice tls-port is out of range");
|
|
564 |
error_report("spice tls-port is out of range");
|
|
565 | 565 |
exit(1); |
566 | 566 |
} |
567 | 567 |
password = qemu_opt_get(opts, "password"); |
... | ... | |
631 | 631 |
#if SPICE_SERVER_VERSION >= 0x000900 /* 0.9.0 */ |
632 | 632 |
if (spice_server_set_sasl_appname(spice_server, "qemu") == -1 || |
633 | 633 |
spice_server_set_sasl(spice_server, 1) == -1) { |
634 |
fprintf(stderr, "spice: failed to enable sasl\n");
|
|
634 |
error_report("spice: failed to enable sasl");
|
|
635 | 635 |
exit(1); |
636 | 636 |
} |
637 | 637 |
#else |
638 |
fprintf(stderr, "spice: sasl is not available (spice >= 0.9 required)\n");
|
|
638 |
error_report("spice: sasl is not available (spice >= 0.9 required)");
|
|
639 | 639 |
exit(1); |
640 | 640 |
#endif |
641 | 641 |
} |
... | ... | |
683 | 683 |
qemu_opt_foreach(opts, add_channel, NULL, 0); |
684 | 684 |
|
685 | 685 |
if (0 != spice_server_init(spice_server, &core_interface)) { |
686 |
fprintf(stderr, "failed to initialize spice server");
|
|
686 |
error_report("failed to initialize spice server");
|
|
687 | 687 |
exit(1); |
688 | 688 |
}; |
689 | 689 |
using_spice = 1; |
... | ... | |
708 | 708 |
{ |
709 | 709 |
if (!spice_server) { |
710 | 710 |
if (QTAILQ_FIRST(&qemu_spice_opts.head) != NULL) { |
711 |
fprintf(stderr, "Oops: spice configured but not active\n");
|
|
711 |
error_report("Oops: spice configured but not active");
|
|
712 | 712 |
exit(1); |
713 | 713 |
} |
714 | 714 |
/* |
Also available in: Unified diff