Skip to content

Commit

Permalink
Ignore return value of function declared with 'warn_unused_result' (#…
Browse files Browse the repository at this point in the history
…84369)

Summary:
X-link: pytorch/pytorch#84369

Pull Request resolved: pytorch#152

Ignore return value of function declared with 'warn_unused_result'

Addresses the following build failure that we get on some of our internal build environments:
caffe2/torch/csrc/deploy/environment.h:60:5: error: ignoring return value of function declared with 'warn_unused_result' attribute [-Werror,-Wunused-result] system(rmCmd.c_str());

Reviewed By: jiyuanzFB, PaliC

Differential Revision: D39181069

fbshipit-source-id: 953eb9e51fd15859bc435b04a1565924865a4b14
  • Loading branch information
David Eklov authored and facebook-github-bot committed Sep 7, 2022
1 parent 192b446 commit fd29304
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion multipy/runtime/environment.h
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ class Environment {
}
virtual ~Environment() {
auto rmCmd = "rm -rf " + extraPythonLibrariesDir_;
system(rmCmd.c_str());
(void)system(rmCmd.c_str());
}
virtual void configureInterpreter(Interpreter* interp) = 0;
virtual const std::vector<std::string>& getExtraPythonPaths() {
Expand Down

0 comments on commit fd29304

Please sign in to comment.