Skip to content

Commit

Permalink
Fix issue #18000467: processgroup truncates buffer
Browse files Browse the repository at this point in the history
Change-Id: I3d98a4da9c47d83d25a11ff0ef94cfcab1feabea
  • Loading branch information
Dianne Hackborn committed Oct 15, 2014
1 parent 2c5e7e1 commit 67f46cb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libprocessgroup/processgroup.cpp
Expand Up @@ -99,7 +99,7 @@ static int refillBuffer(struct ctx *ctx)
}

ctx->buf_len += ret;
ctx->buf[ctx->buf_len-1] = 0;
ctx->buf[ctx->buf_len] = 0;
SLOGV("Read %d to buffer: %s", ret, ctx->buf);

assert(ctx->buf_len <= sizeof(ctx->buf));
Expand Down

0 comments on commit 67f46cb

Please sign in to comment.