mirror of
https://github.com/bytecodealliance/wasm-micro-runtime.git
synced 2025-02-11 17:35:13 +00:00
debug_engine: Fix a few typos (#1261)
no functional changes are intended. cf. https://sourceware.org/gdb/onlinedocs/gdb/General-Query-Packets.html#General-Query-Packets
This commit is contained in:
parent
2b49a0b817
commit
653efecd02
|
@ -1201,11 +1201,11 @@ wasm_debug_instance_get_global(WASMDebugInstance *instance, int32 frame_index,
|
|||
|
||||
uint64
|
||||
wasm_debug_instance_mmap(WASMDebugInstance *instance, uint32 size,
|
||||
int32 map_port)
|
||||
int32 map_prot)
|
||||
{
|
||||
WASMExecEnv *exec_env;
|
||||
uint32 offset = 0;
|
||||
(void)map_port;
|
||||
(void)map_prot;
|
||||
|
||||
if (!instance)
|
||||
return 0;
|
||||
|
|
|
@ -217,7 +217,7 @@ wasm_debug_instance_get_current_object_name(WASMDebugInstance *instance,
|
|||
|
||||
uint64
|
||||
wasm_debug_instance_mmap(WASMDebugInstance *instance, uint32 size,
|
||||
int32 map_port);
|
||||
int32 map_prot);
|
||||
|
||||
bool
|
||||
wasm_debug_instance_ummap(WASMDebugInstance *instance, uint64 addr);
|
||||
|
|
|
@ -19,8 +19,8 @@ struct packet_handler_elem {
|
|||
#define DEL_HANDLER(r, h) [r] = { .request = r, .handler = h }
|
||||
|
||||
static struct packet_handler_elem packet_handler_table[255] = {
|
||||
DEL_HANDLER('Q', handle_generay_set),
|
||||
DEL_HANDLER('q', handle_generay_query),
|
||||
DEL_HANDLER('Q', handle_general_set),
|
||||
DEL_HANDLER('q', handle_general_query),
|
||||
DEL_HANDLER('v', handle_v_packet),
|
||||
DEL_HANDLER('?', handle_threadstop_request),
|
||||
DEL_HANDLER('H', handle_set_current_thread),
|
||||
|
|
|
@ -33,7 +33,7 @@ handle_interrupt(WASMGDBServer *server)
|
|||
}
|
||||
|
||||
void
|
||||
handle_generay_set(WASMGDBServer *server, char *payload)
|
||||
handle_general_set(WASMGDBServer *server, char *payload)
|
||||
{
|
||||
const char *name;
|
||||
char *args;
|
||||
|
@ -141,7 +141,7 @@ process_wasm_global(WASMGDBServer *server, char *args)
|
|||
}
|
||||
|
||||
void
|
||||
handle_generay_query(WASMGDBServer *server, char *payload)
|
||||
handle_general_query(WASMGDBServer *server, char *payload)
|
||||
{
|
||||
const char *name;
|
||||
char *args;
|
||||
|
@ -179,7 +179,7 @@ handle_generay_query(WASMGDBServer *server, char *payload)
|
|||
name = args;
|
||||
|
||||
if (!args) {
|
||||
LOG_ERROR("payload parse error during handle_generay_query");
|
||||
LOG_ERROR("payload parse error during handle_general_query");
|
||||
return;
|
||||
}
|
||||
|
||||
|
@ -669,7 +669,7 @@ handle_malloc(WASMGDBServer *server, char *payload)
|
|||
{
|
||||
char *args;
|
||||
uint64 addr, size;
|
||||
int32 map_port = MMAP_PROT_NONE;
|
||||
int32 map_prot = MMAP_PROT_NONE;
|
||||
|
||||
args = strstr(payload, ",");
|
||||
if (args) {
|
||||
|
@ -687,19 +687,19 @@ handle_malloc(WASMGDBServer *server, char *payload)
|
|||
if (size > 0) {
|
||||
while (*args) {
|
||||
if (*args == 'r') {
|
||||
map_port |= MMAP_PROT_READ;
|
||||
map_prot |= MMAP_PROT_READ;
|
||||
}
|
||||
if (*args == 'w') {
|
||||
map_port |= MMAP_PROT_WRITE;
|
||||
map_prot |= MMAP_PROT_WRITE;
|
||||
}
|
||||
if (*args == 'x') {
|
||||
map_port |= MMAP_PROT_EXEC;
|
||||
map_prot |= MMAP_PROT_EXEC;
|
||||
}
|
||||
args++;
|
||||
}
|
||||
addr = wasm_debug_instance_mmap(
|
||||
(WASMDebugInstance *)server->thread->debug_instance, size,
|
||||
map_port);
|
||||
map_prot);
|
||||
if (addr) {
|
||||
snprintf(tmpbuf, sizeof(tmpbuf), "%" PRIx64, addr);
|
||||
}
|
||||
|
|
|
@ -18,10 +18,10 @@ void
|
|||
handle_interrupt(WASMGDBServer *server);
|
||||
|
||||
void
|
||||
handle_generay_set(WASMGDBServer *server, char *payload);
|
||||
handle_general_set(WASMGDBServer *server, char *payload);
|
||||
|
||||
void
|
||||
handle_generay_query(WASMGDBServer *server, char *payload);
|
||||
handle_general_query(WASMGDBServer *server, char *payload);
|
||||
|
||||
void
|
||||
handle_v_packet(WASMGDBServer *server, char *payload);
|
||||
|
|
Loading…
Reference in New Issue
Block a user