prevent nodogsplash from crashing when token/redir is not set - thanks to Moritz...
authorMirko Vogt <[email protected]>
Thu, 31 May 2012 19:23:13 +0000 (19:23 +0000)
committerMirko Vogt <[email protected]>
Thu, 31 May 2012 19:23:13 +0000 (19:23 +0000)
SVN-Revision: 32017

net/nodogsplash/patches/001-crash_on_missing_rdir_param.patch [new file with mode: 0644]

diff --git a/net/nodogsplash/patches/001-crash_on_missing_rdir_param.patch b/net/nodogsplash/patches/001-crash_on_missing_rdir_param.patch
new file mode 100644 (file)
index 0000000..6bcf2e9
--- /dev/null
@@ -0,0 +1,18 @@
+--- a/src/http.c
++++ b/src/http.c
+@@ -455,10 +455,15 @@ http_nodogsplash_decode_authtarget(reque
+   var = httpdGetVariableByName(r,"tok");
+   if(var && var->value) {
+     token = var->value;
++  } else {
++    token = "";
+   }
++
+   var = httpdGetVariableByName(r,"redir");
+   if(var && var->value) {
+     redir = var->value;
++  } else {
++    redir = "";
+   }
+   authtarget = http_nodogsplash_make_authtarget(token,redir);