After updating to r340179+755e0ab1085 I was unable to start my windows vm with a fbuf device. e.g -s 7,fbuf,tcp=127.0.0.1:5900,w=1024,h=768 Output: getaddrinfo: hostname nor servname provided, or not known device emulation initialization error: Bad file descriptor after doing a little debugging; It looks as though bhyve is passing in freed pointers in the arguments to to rfb_init due to the change in base r340044 removing the added free in pci_fbuf.c, fixed the issue for me.
(In reply to Wes Maag from comment #0) Hm, looks as though my revision was off by one should be base r340045
Indeed, r340045 is bogus. Either the assignments to rfb_host and rfb_password should be strdup()ing the value, or the commit should simply be reverted.
A commit references this bug: Author: araujo Date: Wed Nov 7 04:20:29 UTC 2018 New revision: 340210 URL: https://svnweb.freebsd.org/changeset/base/340210 Log: Revert my bogus attempt to silence coverity on r340045, it created more bad side effects than good. PR: 233038 Submitted by: We Maag <jwmaag@gmail.com> Changes: head/usr.sbin/bhyve/pci_fbuf.c
Thank you all and sorry the breakage!!! I have reverted the commit till I figure out a better way to fix the Coverity issue. Best,
A commit references this bug: Author: seanc Date: Thu Jul 11 19:41:15 UTC 2019 New revision: 349918 URL: https://svnweb.freebsd.org/changeset/base/349918 Log: usr.sbin/bhyve: free leaked memory during option parsing Also update to use strsep(3) instead of strtok(3). Most of this commit inadvertently ended up in r349914. Coverity CID: 1357337 Approved by: markj PR: 233038 Differential Revision: https://reviews.freebsd.org/D20918 Changes: head/usr.sbin/bhyve/pci_fbuf.c