Hello,
the change to the defintion of 'const char *vbuf' in rfb.c is wrong.
The protocol version string must be send as "RFB 003.008\n" and not as
"RFB 003.008\n\r", otherwise the VNC client isn't able to complete the
handshake (it doesn't recognize the protocol version). While it stays
connected, it doesn't show anything.

This patch fixes it for me:

diff --git a/usr.sbin/bhyve/rfb.c b/usr.sbin/bhyve/rfb.c
index b8fe6e3137d..9c8c6eb0764 100644
--- a/usr.sbin/bhyve/rfb.c
+++ b/usr.sbin/bhyve/rfb.c
@@ -744,7 +744,7 @@ rfb_wr_thr(void *arg)
 void
 rfb_handle(struct rfb_softc *rc, int cfd)
 {
-       const char *vbuf = "RFB 003.008\n\r";
+       const char *vbuf = "RFB 003.008\n";
        unsigned char buf[80];
        unsigned char *message = NULL;

Regards,
Yamagi


On Mon, 2 Dec 2019 20:51:47 +0000 (UTC)
Vincenzo Maffione <vmaffi...@freebsd.org> wrote:

> Author: vmaffione
> Date: Mon Dec  2 20:51:46 2019
> New Revision: 355301
> URL: https://svnweb.freebsd.org/changeset/base/355301
> 
> Log:
>   bhyve: uniform printf format string newlines
>   
>   Some of the printf statements only use LF to get a newline. However, a CR 
> character is also required for the serial console to print debug logs in a 
> nice way.
>   Fix those code locations that only use LF, by adding a CR character.
>   
>   Reviewed by:        markj, aleksandr.fedo...@itglobal.com
>   MFC after:  1 week
>   Differential Revision:      https://reviews.freebsd.org/D22552

Attachment: pgpTu2lVO_Kdz.pgp
Description: PGP signature

Reply via email to