From 85846d4c01d30e9600e60308eda62f71f470afeb Mon Sep 17 00:00:00 2001 From: Scott Jackson Date: Fri, 23 Jan 2015 17:20:17 -0800 Subject: Fix bad html encoding when ' is part of query --- src/github/daneren2005/dsub/service/RESTMusicService.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/github') diff --git a/src/github/daneren2005/dsub/service/RESTMusicService.java b/src/github/daneren2005/dsub/service/RESTMusicService.java index cd0ae376..f0144ee4 100644 --- a/src/github/daneren2005/dsub/service/RESTMusicService.java +++ b/src/github/daneren2005/dsub/service/RESTMusicService.java @@ -65,6 +65,7 @@ import android.graphics.Bitmap; import android.net.ConnectivityManager; import android.net.NetworkInfo; import android.os.Looper; +import android.support.v4.text.TextUtilsCompat; import android.util.Log; import github.daneren2005.dsub.R; import github.daneren2005.dsub.domain.*; @@ -1601,7 +1602,7 @@ public class RESTMusicService implements MusicService { StringBuilder builder = new StringBuilder(url); for (int i = 0; i < parameterNames.size(); i++) { builder.append("&").append(parameterNames.get(i)).append("="); - builder.append(URLEncoder.encode(String.valueOf(parameterValues.get(i)), "UTF-8")); + builder.append(TextUtilsCompat.htmlEncode(String.valueOf(parameterValues.get(i)))); } url = builder.toString(); parameterNames = null; -- cgit v1.2.3