Skip to content

Commit 78444ab

Browse files
David Eklovfacebook-github-bot
authored andcommitted
Ignore return value of function declared with 'warn_unused_result' (#169)
Summary: Pull Request resolved: #169 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()); When building locally on a dev server, this compiles just fine, but when building in service lab produced the above build error. Reviewed By: PaliC Differential Revision: D39363916 fbshipit-source-id: 26496c629856284ddddd93d21bc6b0548223207a
1 parent 1437547 commit 78444ab

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

multipy/runtime/environment.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ class Environment {
6666
}
6767
virtual ~Environment() {
6868
auto rmCmd = "rm -rf " + extraPythonLibrariesDir_;
69-
system(rmCmd.c_str());
69+
(void)system(rmCmd.c_str());
7070
}
7171
virtual void configureInterpreter(Interpreter* interp) = 0;
7272
virtual const std::vector<std::string>& getExtraPythonPaths() {

0 commit comments

Comments
 (0)