summaryrefslogtreecommitdiffstats
path: root/bitbake/lib/toaster/toastergui/views.py
diff options
context:
space:
mode:
authorMichael Wood <michael.g.wood@intel.com>2016-02-18 21:21:52 -0800
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-02-19 15:38:49 +0000
commit8c0ba8d9aff6dec6e458739aafb79b185e951afd (patch)
treec313aee588e64a3f918f564fda203c4d2cfc9d82 /bitbake/lib/toaster/toastergui/views.py
parent913e9b1cbc54a6363f08a4e15c64188eab91aeef (diff)
downloadpoky-8c0ba8d9aff6dec6e458739aafb79b185e951afd.tar.gz
bitbake: toaster: toastergui Fix invalid char test and implementation
This test was passing but because the assertion was the wrong way round and should have expected the first one to pass and second one to fail, in reality both were failing as the method for checking the invalid char was incorrect. (Bitbake rev: 932a92b8130d4815656dc885f0c6e4afa4502022) Signed-off-by: Michael Wood <michael.g.wood@intel.com> Signed-off-by: brian avery <avery.brian@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/lib/toaster/toastergui/views.py')
-rwxr-xr-xbitbake/lib/toaster/toastergui/views.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/bitbake/lib/toaster/toastergui/views.py b/bitbake/lib/toaster/toastergui/views.py
index dfa256e8ea..13489af6fd 100755
--- a/bitbake/lib/toaster/toastergui/views.py
+++ b/bitbake/lib/toaster/toastergui/views.py
@@ -2185,8 +2185,11 @@ if True:
2185 layers_added = []; 2185 layers_added = [];
2186 2186
2187 # Rudimentary check for any possible html tags 2187 # Rudimentary check for any possible html tags
2188 if "<" in request.POST: 2188 for val in request.POST.values():
2189 return HttpResponse(jsonfilter({"error": "Invalid character <"}), content_type = "application/json") 2189 if "<" in val:
2190 return HttpResponse(jsonfilter(
2191 {"error": "Invalid character <"}),
2192 content_type="application/json")
2190 2193
2191 prj = Project.objects.get(pk=request.POST['project_id']) 2194 prj = Project.objects.get(pk=request.POST['project_id'])
2192 2195