projects
/
racktables
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
58f694d
)
r4236 gwSendFile(): add type check
author
Denis Ovsienko
<infrastation@yandex.ru>
Thu, 17 Feb 2011 11:05:09 +0000
(11:05 +0000)
committer
Denis Ovsienko
<infrastation@yandex.ru>
Thu, 17 Feb 2011 11:05:09 +0000
(11:05 +0000)
wwwroot/inc/gateways.php
patch
|
blob
|
blame
|
history
diff --git
a/wwwroot/inc/gateways.php
b/wwwroot/inc/gateways.php
index 80b2ba7927106141e70f69c7a57aa300a942da48..033144e5d3f52aae271acc244744b45313b481b5 100644
(file)
--- a/
wwwroot/inc/gateways.php
+++ b/
wwwroot/inc/gateways.php
@@
-229,6
+229,8
@@
function setSwitchVLANs ($object_id = 0, $setcmd)
// installer script.
function gwSendFile ($endpoint, $handlername, $filetext = array())
{
+ if (! is_array ($filetext))
+ throw new InvalidArgException ('filetext', '(suppressed)', 'is not an array');
global $remote_username;
$tmpnames = array();
$endpoint = str_replace (' ', '\ ', $endpoint); // the gateway dispatcher uses read (1) to assign arguments