aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/drivers/unix/ttsl_drv.c
diff options
context:
space:
mode:
authorHenrik Nord <[email protected]>2015-08-20 10:14:16 +0200
committerHenrik Nord <[email protected]>2015-08-20 10:14:16 +0200
commite3a5ad489d6e6cc190b609f8648b6af993c1b333 (patch)
treee1d401a2e0a74ba22f6d5b908a793eea8b37f88b /erts/emulator/drivers/unix/ttsl_drv.c
parenta2670f0822fc6729df956c8ec8c381340ff0a5fb (diff)
parent6b4c2dbd1b4a30f421611987acec6315c62ac9d5 (diff)
downloadotp-e3a5ad489d6e6cc190b609f8648b6af993c1b333.tar.gz
otp-e3a5ad489d6e6cc190b609f8648b6af993c1b333.tar.bz2
otp-e3a5ad489d6e6cc190b609f8648b6af993c1b333.zip
Merge branch 'maint-18' into maint
Diffstat (limited to 'erts/emulator/drivers/unix/ttsl_drv.c')
-rw-r--r--erts/emulator/drivers/unix/ttsl_drv.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/erts/emulator/drivers/unix/ttsl_drv.c b/erts/emulator/drivers/unix/ttsl_drv.c
index 0f773b69fb..53146e71f0 100644
--- a/erts/emulator/drivers/unix/ttsl_drv.c
+++ b/erts/emulator/drivers/unix/ttsl_drv.c
@@ -720,6 +720,7 @@ static void ttysl_from_erlang(ErlDrvData ttysl_data, char* buf, ErlDrvSizeT coun
}
driver_enq_bin(ttysl_port,putcbuf,0,putcpos);
+ driver_free_binary(putcbuf);
if (sz == 0) {
for (;;) {
@@ -1207,6 +1208,7 @@ static int outc(int c)
putcbuf->orig_bytes[putcpos++] = c;
if (putcpos == putclen) {
driver_enq_bin(ttysl_port,putcbuf,0,putclen);
+ driver_free_binary(putcbuf);
putcpos = 0;
putclen = TTY_BUFFSIZE;
putcbuf = driver_alloc_binary(BUFSIZ);