[SERVER-66904] Coverity analysis defect 122289: Not restoring ostream format Created: 31/May/22  Updated: 29/Oct/23  Resolved: 07/Jun/22

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 6.1.0-rc0

Type: Bug Priority: Major - P3
Reporter: Coverity Collector User Assignee: Sergey Galtsev (Inactive)
Resolution: Fixed Votes: 0
Labels: coverity
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
duplicates SERVER-64161 Coverity analysis defect 121627: Not ... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Security 2022-06-13
Participants:

 Description   

Not restoring ostream format

The next output operation may not expect the stream format state being altered, resulting in incorrectly formatted output. Not restoring the stream format state of an ostream
/src/mongo/db/modules/enterprise/src/fle/lib/mongo_crypt_test.cpp:284: STREAM_FORMAT_STATE 122289 "hex" changes the format state of "std::cerr" for category basefield.
/src/mongo/db/modules/enterprise/src/fle/lib/mongo_crypt_test.cpp:288: STREAM_FORMAT_STATE 122289 Changing format state of stream "std::cerr" for category basefield without later restoring it.



 Comments   
Comment by Githook User [ 07/Jun/22 ]

Author:

{'name': 'sergey.galtsev', 'email': 'sergey.galtsev@mongodb.com', 'username': 'brushless-glitch'}

Message: SERVER-66904 restore stderr format after hex
Branch: master
https://github.com/10gen/mongo-enterprise-modules/commit/45954134ce1ef9129eb3c776877b261a38321afb

Generated at Thu Feb 08 06:06:44 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.