2024-05-29 Fred Gleason <fredg@paravelsystems.com>

* Changed the socket type from SOCK_STREAM to SOCK_SEQPACKET in
	the 'RDUnixServer' and 'RDUnixSocket' classes.
	* Removed the resynchronization code from the 'RDJsonFramer' class.
	* Fixed a bug in rdpadd(8) that could cause corruption when processing
	JSON updates.

Signed-off-by: Fred Gleason <fredg@paravelsystems.com>
This commit is contained in:
Fred Gleason
2024-05-29 11:56:02 -04:00
parent d422d12a5b
commit c4e6914c29
5 changed files with 11 additions and 56 deletions

View File

@@ -77,7 +77,7 @@ bool RDUnixServer::listenToPathname(const QString &pathname)
{
struct sockaddr_un sa;
if((unix_socket=socket(AF_UNIX,SOCK_STREAM,0))<0) {
if((unix_socket=socket(AF_UNIX,SOCK_SEQPACKET,0))<0) {
unix_error_string=QString("unable to create socket")+" ["+
QString(strerror(errno))+"]";
return false;
@@ -108,7 +108,7 @@ bool RDUnixServer::listenToAbstract(const QString &addr)
{
struct sockaddr_un sa;
if((unix_socket=socket(AF_UNIX,SOCK_STREAM,0))<0) {
if((unix_socket=socket(AF_UNIX,SOCK_SEQPACKET,0))<0) {
unix_error_string=QString("unable to create socket")+" ["+
QString(strerror(errno))+"]";
return false;