[CDRIVER-1455] ismaster_ssl test leaves client sometimes uninitialized Created: 05/Aug/16  Updated: 10/Aug/16  Resolved: 09/Aug/16

Status: Closed
Project: C Driver
Component/s: None
Affects Version/s: None
Fix Version/s: 1.4.0

Type: Bug Priority: Major - P3
Reporter: Hannes Magnusson Assignee: Hannes Magnusson
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

 
tests/test-mongoc-async.c:95:8: warning: variable 'client' is used uninitialized whenever 'if' condition is true [-Wsometimes-uninitialized]
   if (with_ssl) {
       ^~~~~~~~
tests/test-mongoc-async.c:119:43: note: uninitialized use occurs here
   future = future_client_command_simple (client, "test",
                                          ^~~~~~
tests/test-mongoc-async.c:95:4: note: remove the 'if' if its condition is always false
   if (with_ssl) {
   ^~~~~~~~~~~~~~~
tests/test-mongoc-async.c:63:27: note: initialize the variable 'client' to silence this warning
   mongoc_client_t *client;
                          ^
                           = NULL



 Comments   
Comment by Hannes Magnusson [ 09/Aug/16 ]

The patch that caused this was reverted

Generated at Wed Feb 07 21:12:36 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.