Re: [PATCH spice-server v2 2/7] smartcard-channel-client: Use log instead of printf

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Oct 08, 2019 at 06:39:19PM +0100, Frediano Ziglio wrote:
> More coherent. Also it's not good for a library to output on
> standard output.
> 
> Signed-off-by: Frediano Ziglio <fziglio@xxxxxxxxxx>

Acked-by: Victor Toso <victortoso@xxxxxxxxxx>

Out of curiosity, have you hit unexpected messages?

> ---
>  server/smartcard-channel-client.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/server/smartcard-channel-client.c b/server/smartcard-channel-client.c
> index d47b442e4..43df902f5 100644
> --- a/server/smartcard-channel-client.c
> +++ b/server/smartcard-channel-client.c
> @@ -276,7 +276,8 @@ bool smartcard_channel_client_handle_message(RedChannelClient *rcc,
>          case VSC_APDU:
>              break; // passed on to device
>          default:
> -            printf("ERROR: unexpected message on smartcard channel\n");
> +            red_channel_warning(red_channel_client_get_channel(rcc),
> +                                "ERROR: unexpected message on smartcard channel");
>              return TRUE;
>      }
>  
> -- 
> 2.21.0
> 
> _______________________________________________
> Spice-devel mailing list
> Spice-devel@xxxxxxxxxxxxxxxxxxxxx
> https://lists.freedesktop.org/mailman/listinfo/spice-devel

Attachment: signature.asc
Description: PGP signature

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/spice-devel

[Index of Archives]     [Linux Virtualization]     [Linux Virtualization]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]