Skip to content

Commit

Permalink
remove scary use of memset
Browse files Browse the repository at this point in the history
  • Loading branch information
berthubert committed Mar 7, 2022
1 parent 0427adb commit 21443e8
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion rtcm.cc
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,8 @@ using namespace std;

void RTCMMessage::parse(const std::string& str)
{
memset(&d_gm, 0, sizeof(d_gm));
d_gm={};
// memset(&d_gm, 0, sizeof(d_gm));
auto gbu=[&str](int offset, int bits) {
return getbitu((const unsigned char*)str.c_str(), offset, bits);
};
Expand Down

0 comments on commit 21443e8

Please sign in to comment.