Commit bc09df11 authored by Geoff Simmons's avatar Geoff Simmons

bugfix -- transcode_n cannot return the concatenated string in the

special case where the encoding and decoding are the same
parent 4917bd95
...@@ -484,7 +484,7 @@ transcode(VRT_CTX, VCL_INT n, VCL_ENUM decs, VCL_ENUM encs, ...@@ -484,7 +484,7 @@ transcode(VRT_CTX, VCL_INT n, VCL_ENUM decs, VCL_ENUM encs,
* If the encoding and decoding are the same, and the decoding was * If the encoding and decoding are the same, and the decoding was
* legal, just return the concatenated string. * legal, just return the concatenated string.
*/ */
if (enc == dec) { if (n == -1 && enc == dec) {
VCL_STRING s; VCL_STRING s;
s = VRT_String(ctx->ws, NULL, p, ap); s = VRT_String(ctx->ws, NULL, p, ap);
return s; return s;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment