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

(-)a/src/protocol/http/org/apache/jmeter/protocol/http/visualizers/RequestViewHTTP.java (-5 / +6 lines)
Lines 339-345 public class RequestViewHTTP implements RequestView { Link Here
339
     * 
339
     * 
340
     * @param query
340
     * @param query
341
     *            to decode
341
     *            to decode
342
     * @return a decode query string
342
     * @return the decoded query string, if it can be url-decoded. Otherwise the original
343
     *            query will be returned.
343
     */
344
     */
344
    public static String decodeQuery(String query) {
345
    public static String decodeQuery(String query) {
345
        if (query != null && query.length() > 0) {
346
        if (query != null && query.length() > 0) {
Lines 347-360 public class RequestViewHTTP implements RequestView { Link Here
347
                query = URLDecoder.decode(query, CHARSET_DECODE); // better ISO-8859-1 than UTF-8
348
                query = URLDecoder.decode(query, CHARSET_DECODE); // better ISO-8859-1 than UTF-8
348
            } catch(IllegalArgumentException e) {
349
            } catch(IllegalArgumentException e) {
349
                log.warn("Error decoding query, maybe your request parameters should be encoded:" + query, e);
350
                log.warn("Error decoding query, maybe your request parameters should be encoded:" + query, e);
350
                return null;
351
                return query;
351
            } catch (UnsupportedEncodingException uee) {
352
            } catch (UnsupportedEncodingException uee) {
352
                log.warn("Error decoding query, maybe your request parameters should be encoded:" + query, uee);
353
                log.warn("Error decoding query, maybe your request parameters should be encoded:" + query, uee);
353
                return null;
354
                return query;
354
            } 
355
            }
355
            return query;
356
            return query;
356
        }
357
        }
357
        return null;
358
        return "";
358
    }
359
    }
359
360
360
    @Override
361
    @Override

Return to bug 59714