diff options
author | Yoichi Hirai <i@yoichihirai.com> | 2017-03-13 23:37:55 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-03-13 23:37:55 +0800 |
commit | 9aab3b8639afa6e30e866e052a412b6f39c6ef6c (patch) | |
tree | 511895fefe1b4cf33df9359663b6537901c56ddf /solc/main.cpp | |
parent | ef8b56a05823e39ffc2577af653200f22d6b15a1 (diff) | |
parent | 31a5e5bfef086c1cac477661dd627fa774bc44f5 (diff) | |
download | dexon-solidity-9aab3b8639afa6e30e866e052a412b6f39c6ef6c.tar dexon-solidity-9aab3b8639afa6e30e866e052a412b6f39c6ef6c.tar.gz dexon-solidity-9aab3b8639afa6e30e866e052a412b6f39c6ef6c.tar.bz2 dexon-solidity-9aab3b8639afa6e30e866e052a412b6f39c6ef6c.tar.lz dexon-solidity-9aab3b8639afa6e30e866e052a412b6f39c6ef6c.tar.xz dexon-solidity-9aab3b8639afa6e30e866e052a412b6f39c6ef6c.tar.zst dexon-solidity-9aab3b8639afa6e30e866e052a412b6f39c6ef6c.zip |
Merge pull request #1768 from ethereum/abortiffileexists
Do not overwrite files unless forced.
Diffstat (limited to 'solc/main.cpp')
-rw-r--r-- | solc/main.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/solc/main.cpp b/solc/main.cpp index 28726e26..c61da6e9 100644 --- a/solc/main.cpp +++ b/solc/main.cpp @@ -58,15 +58,16 @@ int main(int argc, char** argv) return 1; if (!cli.processInput()) return 1; + bool success = false; try { - cli.actOnInput(); + success = cli.actOnInput(); } catch (boost::exception const& _exception) { cerr << "Exception during output generation: " << boost::diagnostic_information(_exception) << endl; - return 1; + success = false; } - return 0; + return success ? 0 : 1; } |