diff options
author | Ted Gould <ted@gould.cx> | 2012-08-29 16:58:05 -0500 |
---|---|---|
committer | Ted Gould <ted@gould.cx> | 2012-08-29 16:58:05 -0500 |
commit | ff6a857303006d1e9e2c920c39cf3a1bca30871f (patch) | |
tree | 68008a85702e841141662d78ae3d51a44c38179f | |
parent | 3116bf28427d598ea3208dba138704c3ea6815ba (diff) | |
download | lightdm-remote-session-freerdp2-ff6a857303006d1e9e2c920c39cf3a1bca30871f.tar.gz lightdm-remote-session-freerdp2-ff6a857303006d1e9e2c920c39cf3a1bca30871f.tar.bz2 lightdm-remote-session-freerdp2-ff6a857303006d1e9e2c920c39cf3a1bca30871f.zip |
Check to ensure we wrote something
-rw-r--r-- | socket-sucker.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/socket-sucker.c b/socket-sucker.c index 54aee32..35424a6 100644 --- a/socket-sucker.c +++ b/socket-sucker.c @@ -43,7 +43,7 @@ main (int argc, char * argv[]) serv_addr.sun_family = AF_UNIX; int printsize = snprintf(serv_addr.sun_path, sizeof(serv_addr.sun_path) - 1, "%s/%s", home, ".freerdp-socket"); - if (printsize > sizeof(serv_addr.sun_path) - 1) { + if (printsize > sizeof(serv_addr.sun_path) - 1 || printsize < 0) { return -1; } |