This macro allow to define magic constants without using weird
memory tweacks.
This remove some possible warning from some compiler and
make code more optimized as compiler is able to compute the
constant.
Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
Add a new string message for sending proxy details.
CONTROLLER_PROXY (ControllerData, string)
The value must be of the form [protocol://]<host>[:port]
The proxy string may be specified with a protocol:// prefix to specify
alternative proxy protocols.
If no protocol is specified in the proxy string or if the string
doesn't match a supported one, the proxy will be treated as a HTTP
proxy.
spice-protocol comes with 2 headers to handle structure packing,
but controller_prot.h and foreign_menu_prot were both using their
own preprocessor definitions to handle packing. It's better to have
structure packing macros centralized since how it's done varies
between compilers, so it may need to change over time.
We are making all text send over the controller socket utf-8, rather then
having somethings as 8 bit (hostname) and others unicode16.
Adjust the CONTROLLER_MENU_*_DELIMITER defines for this.