]> source.dussan.org Git - tigervnc.git/commit
Return static char buffer from some methods
authorPierre Ossman <ossman@cendio.se>
Fri, 13 Jan 2023 10:14:21 +0000 (11:14 +0100)
committerPierre Ossman <ossman@cendio.se>
Sat, 4 Feb 2023 13:03:13 +0000 (14:03 +0100)
commit5c1ac16776cd9f2a75e31086755e72186b3b3d41
tree234a54c7f11c25ba59f8487118d13eb550c1cc64
parent1af2a56f7583b301890f8ea213f262782cc3c9f1
Return static char buffer from some methods

This mimics how some system functions (like inet_ntop()) work, and
avoids complexity around ownership of the returned string buffer.

The downside is that the string must be consumed directly as it will be
overwritten on the next call, but that is not an issue with the current
usage.
24 files changed:
common/network/Socket.h
common/network/TcpSocket.cxx
common/network/TcpSocket.h
common/network/UnixSocket.cxx
common/network/UnixSocket.h
common/os/os.cxx
common/os/os.h
common/rfb/CSecurityTLS.cxx
common/rfb/VNCSConnectionST.cxx
common/rfb/VNCServerST.cxx
unix/vncpasswd/vncpasswd.cxx
unix/x0vncserver/XDesktop.cxx
unix/xserver/hw/vnc/XserverDesktop.cc
vncviewer/CConn.cxx
vncviewer/ServerDialog.cxx
vncviewer/parameters.cxx
vncviewer/vncviewer.cxx
win/rfb_win32/Dialog.cxx
win/rfb_win32/Dialog.h
win/rfb_win32/Service.cxx
win/rfb_win32/Service.h
win/vncconfig/Connections.h
win/vncconfig/PasswordDialog.cxx
win/winvnc/QueryConnectDialog.cxx