Small tweak to previous patch (already fed upstream), and bump. The intended behavior of this example is to print the value of every named environment variable, or "<unset>" if the environment variable isn't set. The original patch accidentally just printed the name of every environment variable regardless of whether or not the environment variable was set (e.g. HTTPS=HTTPS). This only affected the example script, websocketd itself still worked fine, but the examples are the best source of websocketd documentation so I think this is useful before release.
Ok? Index: Makefile =================================================================== RCS file: /work/cvsroot/ports/net/websocketd/Makefile,v retrieving revision 1.5 diff -p -u -r1.5 Makefile --- Makefile 20 Jul 2015 20:53:58 -0000 1.5 +++ Makefile 27 Jul 2015 17:45:59 -0000 @@ -8,6 +8,7 @@ DISTNAME = websocketd-$V GH_ACCOUNT = joewalnes GH_PROJECT = websocketd GH_TAGNAME = v$V +REVISION = 0 CATEGORIES = net www Index: patches/patch-examples_cgi-bin_dump-env_sh =================================================================== RCS file: /work/cvsroot/ports/net/websocketd/patches/patch-examples_cgi-bin_dump-env_sh,v retrieving revision 1.1 diff -p -u -r1.1 patch-examples_cgi-bin_dump-env_sh --- patches/patch-examples_cgi-bin_dump-env_sh 20 Jul 2015 20:53:59 -0000 1.1 +++ patches/patch-examples_cgi-bin_dump-env_sh 27 Jul 2015 17:47:22 -0000 @@ -9,12 +9,13 @@ Drop Bash and tweak to work with our ksh # Copyright 2013 Joe Walnes and the websocketd team. # All rights reserved. -@@ -36,7 +36,7 @@ echo +@@ -36,7 +36,8 @@ echo for NAME in ${NAMES} do - echo ${NAME}=${!NAME:-<unset>} -+ echo ${NAME}=${NAME:-<unset>} ++ eval "value=\${${NAME}}" ++ echo ${NAME}=${value:-<unset>} done # Additional HTTP headers