summaryrefslogtreecommitdiffstats
path: root/libxrdp/libxrdp.c
diff options
context:
space:
mode:
authorJay Sorg <jay.sorg@gmail.com>2014-03-22 00:28:52 -0700
committerJay Sorg <jay.sorg@gmail.com>2014-03-22 00:28:52 -0700
commite840c8f335335fd30832eb4ff3991ad0e44557ac (patch)
tree4d4d431161adf53736ead46b9b8443040cc5209f /libxrdp/libxrdp.c
parentab73d48fb3f8308e0b08c5ca3fbf4a242df75a77 (diff)
downloadxrdp-proprietary-e840c8f335335fd30832eb4ff3991ad0e44557ac.tar.gz
xrdp-proprietary-e840c8f335335fd30832eb4ff3991ad0e44557ac.zip
libxrdp: memory leak fixes on error
Diffstat (limited to 'libxrdp/libxrdp.c')
-rw-r--r--libxrdp/libxrdp.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libxrdp/libxrdp.c b/libxrdp/libxrdp.c
index 0d8e030e..e9c3508b 100644
--- a/libxrdp/libxrdp.c
+++ b/libxrdp/libxrdp.c
@@ -623,6 +623,7 @@ libxrdp_send_pointer(struct xrdp_session *session, int cache_idx,
LLOGLN(10, ("libxrdp_send_pointer: fastpath"));
if (xrdp_rdp_init_fastpath((struct xrdp_rdp *)session->rdp, s) != 0)
{
+ free_stream(s);
return 1;
}
@@ -716,6 +717,7 @@ libxrdp_send_pointer(struct xrdp_session *session, int cache_idx,
if (xrdp_rdp_send_fastpath((struct xrdp_rdp *)session->rdp, s,
FASTPATH_UPDATETYPE_COLOR) != 0)
{
+ free_stream(s);
return 1;
}
}
@@ -724,6 +726,7 @@ libxrdp_send_pointer(struct xrdp_session *session, int cache_idx,
if (xrdp_rdp_send_fastpath((struct xrdp_rdp *)session->rdp, s,
FASTPATH_UPDATETYPE_POINTER) != 0)
{
+ free_stream(s);
return 1;
}
}