View | Details | Raw Unified | Return to bug 58852
Collapse All | Expand All

(-)a/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC3Impl.java (-6 / +1 lines)
Lines 1032-1043 public class HTTPHC3Impl extends HTTPHCAbstractImpl { Link Here
1032
            // If the request entity is repeatable, we can send it first to
1032
            // If the request entity is repeatable, we can send it first to
1033
            // our own stream, so we can return it
1033
            // our own stream, so we can return it
1034
            if(put.getRequestEntity().isRepeatable()) {
1034
            if(put.getRequestEntity().isRepeatable()) {
1035
                ByteArrayOutputStream bos = new ByteArrayOutputStream();
1035
                putBody.append("<actual file content, not shown here>");
1036
                put.getRequestEntity().writeRequest(bos);
1037
                bos.flush();
1038
                // We get the posted bytes using the charset that was used to create them
1039
                putBody.append(new String(bos.toByteArray(),put.getRequestCharSet()));
1040
                bos.close();
1041
            }
1036
            }
1042
            else {
1037
            else {
1043
                putBody.append("<RequestEntity was not repeatable, cannot view what was sent>");
1038
                putBody.append("<RequestEntity was not repeatable, cannot view what was sent>");
(-)a/src/protocol/http/org/apache/jmeter/protocol/http/sampler/HTTPHC4Impl.java (-7 / +1 lines)
Lines 1336-1347 public class HTTPHC4Impl extends HTTPHCAbstractImpl { Link Here
1336
            // our own stream, so we can return it
1336
            // our own stream, so we can return it
1337
            final HttpEntity entityEntry = entity.getEntity();
1337
            final HttpEntity entityEntry = entity.getEntity();
1338
            if(entityEntry.isRepeatable()) {
1338
            if(entityEntry.isRepeatable()) {
1339
                ByteArrayOutputStream bos = new ByteArrayOutputStream();
1339
                entityBody.append("<actual file content, not shown here>");
1340
                entityEntry.writeTo(bos);
1341
                bos.flush();
1342
                // We get the posted bytes using the charset that was used to create them
1343
                entityBody.append(new String(bos.toByteArray(), charset));
1344
                bos.close();
1345
            }
1340
            }
1346
            else { // this probably cannot happen
1341
            else { // this probably cannot happen
1347
                entityBody.append("<RequestEntity was not repeatable, cannot view what was sent>");
1342
                entityBody.append("<RequestEntity was not repeatable, cannot view what was sent>");
1348
- 

Return to bug 58852