Skip to content

Commit

Permalink
reduce warnings (#5171)
Browse files Browse the repository at this point in the history
* reduce warnings

* correct type
  • Loading branch information
Jeffrey Mendelsohn authored and GitHub Enterprise committed Jan 17, 2025
1 parent d53f30b commit 34450f5
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions groups/bal/balcl/balcl_commandline.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -970,8 +970,8 @@ int CommandLine::parseImp(bsl::ostream& errorStream)
// have to stop whenever an option isn't a flag, as in Gnu tar, e.g.,
// "-zcvf filename".)

int index;
const char *s = &d_arguments[i].c_str()[1];
int index = 0;
const char *s = &d_arguments[i].c_str()[1];
while (*s && (index = findTag(*s)) != -1
&& OptionInfo::e_FLAG == d_options[index].argType()) {

Expand Down
4 changes: 2 additions & 2 deletions groups/bal/baltzo/baltzo_localdatetime.t.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -943,8 +943,8 @@ int main(int argc, char *argv[])
Obj *objPtr = 0;

bslma::TestAllocator *objAllocatorPtr = 0;
bsls::Types::Int64 s1Alloc = s1.numBytesInUse();
bsls::Types::Int64 objAlloc;
bsls::Types::Int64 s1Alloc = s1.numBytesInUse();
bsls::Types::Int64 objAlloc = 0;

switch (CONFIG) {
case 'a': {
Expand Down
4 changes: 2 additions & 2 deletions groups/bal/baltzo/baltzo_localtimedescriptor.t.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1737,8 +1737,8 @@ int main(int argc, char *argv[])
Obj &mF = *fromPtr; const Obj& F = mF;
bsls::Types::Int64 s1Alloc = s1.numBytesInUse();

Obj *objPtr = 0;
bsls::Types::Int64 objAlloc;
Obj *objPtr = 0;
bsls::Types::Int64 objAlloc = 0;
bslma::TestAllocator *objAllocatorPtr = 0;

switch (CONFIG) {
Expand Down

0 comments on commit 34450f5

Please sign in to comment.