diff options
author | Ted Trask <ttrask01@yahoo.com> | 2015-06-01 14:50:06 -0400 |
---|---|---|
committer | Ted Trask <ttrask01@yahoo.com> | 2015-06-01 14:50:06 -0400 |
commit | e2c49e8abf7e7d0204bcce84919cd49795da4290 (patch) | |
tree | 4bdff6c64d406b438367985cd57cec2a1caef3ad /cgi-bin | |
parent | f173efd61b9ce8582cd8ddad63fbbbcf8c3f2093 (diff) | |
download | acf-provisioning-e2c49e8abf7e7d0204bcce84919cd49795da4290.tar.bz2 acf-provisioning-e2c49e8abf7e7d0204bcce84919cd49795da4290.tar.xz |
Fix provisioning.cgi to work with haserl-0.9.33 and later
Diffstat (limited to 'cgi-bin')
-rwxr-xr-x | cgi-bin/provisioning.cgi | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/cgi-bin/provisioning.cgi b/cgi-bin/provisioning.cgi index 6cc53c9..ae4255c 100755 --- a/cgi-bin/provisioning.cgi +++ b/cgi-bin/provisioning.cgi @@ -138,7 +138,12 @@ if ( request_method == "GET" ) then APP:dispatch("/provisioning/", "provisioning", "getfile", clientdata) APP:destroy() elseif ( request_method == "PUT" ) then - local data = io.stdin:read("*all") + local data + if POST and POST.body and POST.body ~= "" then + data = POST.body + else + data = io.stdin:read("*all") + end local success = true -- Protect against writing to arbitrary paths |