aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator
diff options
context:
space:
mode:
authorLukas Larsson <[email protected]>2013-08-23 12:18:36 +0200
committerLukas Larsson <[email protected]>2013-08-23 12:18:36 +0200
commit71f5252a3177c4a2151b0eb9f81c4d49308264f8 (patch)
tree40e19d39735ca6f1891d47873fe95716098f0467 /erts/emulator
parent424021bb4253cbf0f864b97666497b82b5da66c1 (diff)
parent3b1d9f46c187ecdad3930c52fa4fbe4d547277c8 (diff)
downloadotp-71f5252a3177c4a2151b0eb9f81c4d49308264f8.tar.gz
otp-71f5252a3177c4a2151b0eb9f81c4d49308264f8.tar.bz2
otp-71f5252a3177c4a2151b0eb9f81c4d49308264f8.zip
Merge branch 'lukas/erts/efile_undef_behaviour/OTP-11246' into maint
* lukas/erts/efile_undef_behaviour/OTP-11246: erts: Fix bug in translating ev macros to functions
Diffstat (limited to 'erts/emulator')
-rw-r--r--erts/emulator/drivers/common/efile_drv.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/erts/emulator/drivers/common/efile_drv.c b/erts/emulator/drivers/common/efile_drv.c
index edcb56de1d..9e95325c24 100644
--- a/erts/emulator/drivers/common/efile_drv.c
+++ b/erts/emulator/drivers/common/efile_drv.c
@@ -553,8 +553,10 @@ efile_ev_get_char(ErlIOVec *ev, char *p, int *pp, int *qp) {
*(p) = *EV_CHAR_P(ev, *(pp), *(qp));
if (*(pp)+1 < (ev)->iov[*(qp)].iov_len)
*(pp) = *(pp)+1;
- else
+ else {
(*(qp))++;
+ *pp = 0;
+ }
return !0;
}
return 0;
@@ -575,8 +577,10 @@ efile_ev_get_uint32(ErlIOVec *ev, Uint32 *p, int *pp, int *qp) {
| (EV_UINT32(ev, *(pp)+3, *(qp)));
if (*(pp)+4 < (ev)->iov[*(qp)].iov_len)
*(pp) = *(pp)+4;
- else
+ else {
(*(qp))++;
+ *pp = 0;
+ }
return !0;
}
return 0;
@@ -601,8 +605,10 @@ efile_ev_get_uint64(ErlIOVec *ev, Uint64 *p, int *pp, int *qp) {
| (EV_UINT64(ev, *(pp)+7, *(qp)));
if (*(pp)+8 < (ev)->iov[*(qp)].iov_len)
*(pp) = *(pp)+8;
- else
+ else {
(*(qp))++;
+ *pp = 0;
+ }
return !0;
}
return 0;