File tree Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Expand file tree Collapse file tree 2 files changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -150,8 +150,9 @@ _crypto_hash_size (mongoc_crypto_t *crypto)
150
150
return MONGOC_SCRAM_SHA_1_HASH_SIZE ;
151
151
} else if (crypto -> algorithm == MONGOC_CRYPTO_ALGORITHM_SHA_256 ) {
152
152
return MONGOC_SCRAM_SHA_256_HASH_SIZE ;
153
+ } else {
154
+ BSON_UNREACHABLE ("Unexpected crypto algorithm" );
153
155
}
154
- return 0 ;
155
156
}
156
157
157
158
/* Wrapper for BCryptDeriveKeyPBKDF2 */
Original file line number Diff line number Diff line change @@ -119,8 +119,9 @@ _scram_hash_size (mongoc_scram_t *scram)
119
119
return MONGOC_SCRAM_SHA_1_HASH_SIZE ;
120
120
} else if (scram -> crypto .algorithm == MONGOC_CRYPTO_ALGORITHM_SHA_256 ) {
121
121
return MONGOC_SCRAM_SHA_256_HASH_SIZE ;
122
+ } else {
123
+ BSON_UNREACHABLE ("Unexpected crypto algorithm" );
122
124
}
123
- return 0 ;
124
125
}
125
126
126
127
/* Copies the cache's secrets to scram */
You can’t perform that action at this time.
0 commit comments