diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/luarocks/util.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/luarocks/util.lua b/src/luarocks/util.lua index 8c4bd974..fc45c9f4 100644 --- a/src/luarocks/util.lua +++ b/src/luarocks/util.lua | |||
@@ -16,8 +16,8 @@ local unpack = unpack or table.unpack | |||
16 | -- @param spec string: "*l" by default, to read a single line. | 16 | -- @param spec string: "*l" by default, to read a single line. |
17 | -- May be used to read more, passing, for instance, "*a". | 17 | -- May be used to read more, passing, for instance, "*a". |
18 | -- @return string: the output of the program. | 18 | -- @return string: the output of the program. |
19 | function popen_read(cmd, spec) | 19 | function util.popen_read(cmd, spec) |
20 | local fd = io.open(cmd) | 20 | local fd = io.popen(cmd) |
21 | local out = fd:read(spec or "*l") | 21 | local out = fd:read(spec or "*l") |
22 | fd:close() | 22 | fd:close() |
23 | return out | 23 | return out |