From: Gordon Hecker Date: Mon, 25 Jan 2010 14:31:43 +0000 (+0100) Subject: bugfix: fix error handling when passing a sourcename to ls-project X-Git-Tag: e2factory-2.3.4pre1~5 X-Git-Url: https://git.e2factory.org/?a=commitdiff_plain;h=3b9c86e37d9d54683484bb3c83756b63b53b253e;p=e2factory.git bugfix: fix error handling when passing a sourcename to ls-project We had functionality to translate from a source to result and list all dependencies, but that lead to ambiguous behaviour where sources and results with the same name exist. So don't accept source names for now. Signed-off-by: Gordon Hecker --- diff --git a/local/ls-project.lua b/local/ls-project.lua index c5fcb3b..b27b2de 100755 --- a/local/ls-project.lua +++ b/local/ls-project.lua @@ -63,7 +63,11 @@ if opts.all then end elseif #opts.arguments > 0 then for _, r in ipairs(opts.arguments) do - table.insert(results, r) + if info.results[r] then + table.insert(results, r) + else + e2lib.abort(new_error("not a result: %s", r)) + end end end if #results > 0 then