Initialize reply structures to avoid segmentation fault in debug
This commit is contained in:
@ -31,6 +31,9 @@ main(int argc, char **argv)
|
|||||||
|
|
||||||
char *device, *addr_str, *xml_result;
|
char *device, *addr_str, *xml_result;
|
||||||
int address, baudrate = 9600;
|
int address, baudrate = 9600;
|
||||||
|
|
||||||
|
memset((void *)&reply, 0, sizeof(mbus_frame));
|
||||||
|
memset((void *)&reply_data, 0, sizeof(mbus_frame_data));
|
||||||
|
|
||||||
if (argc == 3)
|
if (argc == 3)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user