-
-
Notifications
You must be signed in to change notification settings - Fork 31.4k
test: fix warning in test_environment.cc #36846
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
test: fix warning in test_environment.cc #36846
Conversation
f5706f3
to
f67a8bd
Compare
cc @nodejs/testing |
The Line 467 in a45a404
|
@targos thanks for mentioning that. I actually tried |
Sorry, it's not a macro for us. The function is defined in |
@targos thanks, now the warning is gone. :) |
warning log: ../test/cctest/test_environment.cc: In constructor ‘RedirectStdErr::RedirectStdErr(const char*)’: ../test/cctest/test_environment.cc:77:12: warning: ignoring return value of ‘FILE* freopen(const char*, const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen(filename_, "w", stderr); ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
9ae438f
to
3e7ef4b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
RSLGTM
Landed in 341bbd3 |
``` warning log: ../test/cctest/test_environment.cc: In constructor \ ‘RedirectStdErr::RedirectStdErr(const char*)’: ../test/cctest/test_environment.cc:77:12: warning: \ ignoring return value of ‘FILE* freopen(const char*, \ const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen(filename_, "w", stderr); ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~ ``` PR-URL: #36846 Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
``` warning log: ../test/cctest/test_environment.cc: In constructor \ ‘RedirectStdErr::RedirectStdErr(const char*)’: ../test/cctest/test_environment.cc:77:12: warning: \ ignoring return value of ‘FILE* freopen(const char*, \ const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen(filename_, "w", stderr); ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~ ``` PR-URL: #36846 Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
``` warning log: ../test/cctest/test_environment.cc: In constructor \ ‘RedirectStdErr::RedirectStdErr(const char*)’: ../test/cctest/test_environment.cc:77:12: warning: \ ignoring return value of ‘FILE* freopen(const char*, \ const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen(filename_, "w", stderr); ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~ ``` PR-URL: #36846 Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
``` warning log: ../test/cctest/test_environment.cc: In constructor \ ‘RedirectStdErr::RedirectStdErr(const char*)’: ../test/cctest/test_environment.cc:77:12: warning: \ ignoring return value of ‘FILE* freopen(const char*, \ const char*, FILE*)’, declared with attribute warn_unused_result [-Wunused-result] freopen(filename_, "w", stderr); ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~ ``` PR-URL: #36846 Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
warning log: