Re: [PATCH 3/5] gdbstub: Use fixed-size array in GdbCmdParseEntry instead of pointer

2021-05-06 Thread Alex Bennée
Philippe Mathieu-Daudé writes: > On 5/6/21 2:01 PM, Alex Bennée wrote: >> >> Philippe Mathieu-Daudé writes: >> >>> GdbCmdParseEntry should have enough room with 20 chars for the command >>> string, and 8 for the schema. Add the GDB_CMD_PARSE_ENTRY_CMD_SIZE and >>> GDB_CMD_PARSE_ENTRY_SCHEMA_

Re: [PATCH 3/5] gdbstub: Use fixed-size array in GdbCmdParseEntry instead of pointer

2021-05-06 Thread Philippe Mathieu-Daudé
On 5/6/21 2:01 PM, Alex Bennée wrote: > > Philippe Mathieu-Daudé writes: > >> GdbCmdParseEntry should have enough room with 20 chars for the command >> string, and 8 for the schema. Add the GDB_CMD_PARSE_ENTRY_CMD_SIZE and >> GDB_CMD_PARSE_ENTRY_SCHEMA_SIZE definitions. >> >> Do not use pointer

Re: [PATCH 3/5] gdbstub: Use fixed-size array in GdbCmdParseEntry instead of pointer

2021-05-06 Thread Alex Bennée
Philippe Mathieu-Daudé writes: > GdbCmdParseEntry should have enough room with 20 chars for the command > string, and 8 for the schema. Add the GDB_CMD_PARSE_ENTRY_CMD_SIZE and > GDB_CMD_PARSE_ENTRY_SCHEMA_SIZE definitions. > > Do not use pointer to string of unknown length, but array of fixed

[PATCH 3/5] gdbstub: Use fixed-size array in GdbCmdParseEntry instead of pointer

2021-05-05 Thread Philippe Mathieu-Daudé
GdbCmdParseEntry should have enough room with 20 chars for the command string, and 8 for the schema. Add the GDB_CMD_PARSE_ENTRY_CMD_SIZE and GDB_CMD_PARSE_ENTRY_SCHEMA_SIZE definitions. Do not use pointer to string of unknown length, but array of fixed size. Having constant size will help use to