Skip to content

Commit

Permalink
SERVER-20819 Coverity analysis defect 76290: Unchecked return value
Browse files Browse the repository at this point in the history
  • Loading branch information
WaleyChen committed Jul 13, 2016
1 parent b62dcab commit e062cda
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/mongo/transport/service_entry_point_utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,11 @@ void launchWrappedServiceEntryWorkerThread(transport::Session&& session,
if (kDebugBuild)
stackSizeToSet /= 2;
#endif
pthread_attr_setstacksize(&attrs, stackSizeToSet);
int failed = pthread_attr_setstacksize(&attrs, stackSizeToSet);
if (failed) {
const auto ewd = errnoWithDescription(failed);
warning() << "pthread_attr_setstacksize failed: " << ewd;
}
} else if (limits.rlim_cur < 1024 * 1024) {
warning() << "Stack size set to " << (limits.rlim_cur / 1024) << "KB. We suggest 1MB";
}
Expand Down

0 comments on commit e062cda

Please sign in to comment.