mirror of
https://github.com/Ed94/raddebugger.git
synced 2026-11-14 18:20:11 -08:00
fix overly-aggressive visualization of unmapped addresses (while read is stale); fix unaligned allocations of xsave blocks in linux_demon; fix some edges in custom window borders in x11
This commit is contained in:
1 parent
e6e0992c63
commit
914c1946b0
4 files changed
+13
-10
No files matched your search
@@ -1764,10 +1764,9 @@ ev_string_iter_next(Arena *arena, EV_StringIter *it, String8 *out_string)
|
||||
{
|
||||
ptr_data->addr_is_good = 1;
|
||||
}
|
||||
else if(e_space_read(ptr_data->value_eval.space, &byte, &range_info, r1u64(ptr_data->value_eval.value.u64, ptr_data->value_eval.value.u64+1)) &&
|
||||
!(range_info.flags & E_SpaceRangeFlag_Stale))
|
||||
else if(e_space_read(ptr_data->value_eval.space, &byte, &range_info, r1u64(ptr_data->value_eval.value.u64, ptr_data->value_eval.value.u64+1)))
|
||||
{
|
||||
ptr_data->addr_is_good = !(byte_bad_flags & 1);
|
||||
ptr_data->addr_is_good = (range_info.flags & E_SpaceRangeFlag_Stale) || !(byte_bad_flags & 1);
|
||||
}
|
||||
}
|
||||
if(ptr_data->did_redirect)
|
||||
|
||||
@@ -1526,7 +1526,7 @@ lnx_dmn_thread_read_reg_block(LNX_DMN_Thread *thread)
|
||||
// get xsave
|
||||
if(x64_is_xsave_supported())
|
||||
{
|
||||
void *xsave_raw = push_array(scratch.arena, U8, process_ctx->xsave_size);
|
||||
void *xsave_raw = push_array_aligned(scratch.arena, U8, process_ctx->xsave_size, 64);
|
||||
int ptrace_result = LNX_RETRY_ON_EINTR(ptrace(PTRACE_GETREGSET, thread->tid, (void *)NT_X86_XSTATE, &(struct iovec){ .iov_len = process_ctx->xsave_size, .iov_base = xsave_raw }));
|
||||
if(ptrace_result < 0) { goto exit; }
|
||||
xsave = xsave_raw;
|
||||
@@ -1536,7 +1536,7 @@ lnx_dmn_thread_read_reg_block(LNX_DMN_Thread *thread)
|
||||
// get fxsave
|
||||
if(fxsave == 0)
|
||||
{
|
||||
fxsave = push_array(scratch.arena, X64_FXSave, 1);
|
||||
fxsave = push_array_aligned(scratch.arena, X64_FXSave, 1, 64);
|
||||
int ptrace_result = LNX_RETRY_ON_EINTR(ptrace(PTRACE_GETREGSET, thread->tid, (void *)NT_FPREGSET, &(struct iovec){ .iov_len = sizeof(*fxsave), .iov_base = fxsave }));
|
||||
if(ptrace_result < 0) { goto exit; }
|
||||
fxsave = 0;
|
||||
@@ -1739,8 +1739,8 @@ lnx_dmn_thread_write_reg_block(LNX_DMN_Thread *thread)
|
||||
|
||||
if(x64_is_xsave_supported())
|
||||
{
|
||||
U8 *xsave_raw = push_array(scratch.arena, U8, process_ctx->xsave_size);
|
||||
X64_XSave *dst = (X64_XSave *)xsave_raw;
|
||||
U8 *xsave_raw = push_array_aligned(scratch.arena, U8, process_ctx->xsave_size, 64);
|
||||
X64_XSave *dst = (X64_XSave *)xsave_raw;
|
||||
dst->fxsave = dst_fxsave;
|
||||
dst->header.xstate_bv |= X64_XStateComponentFlag_FP;
|
||||
dst->header.xstate_bv |= X64_XStateComponentFlag_SSE;
|
||||
|
||||
@@ -48,7 +48,7 @@ lnx_moveresize_code_from_pos(LNX_WM_Window *window, Vec2F32 pos, B32 *out_is_in_
|
||||
Rng2F32 title_bar_rect = r2f32p(window_rect.x0 + window->custom_edge_thickness,
|
||||
window_rect.y0 + window->custom_edge_thickness,
|
||||
window_rect.x1 - window->custom_edge_thickness,
|
||||
window_rect.y0 + window->custom_title_bar_thickness);
|
||||
window_rect.y0 + window->custom_edge_thickness + window->custom_title_bar_thickness);
|
||||
if(contains_2f32(title_bar_rect, pos))
|
||||
{
|
||||
moveresize_code = _NET_WM_MOVERESIZE_MOVE;
|
||||
@@ -87,6 +87,10 @@ lnx_moveresize_code_from_pos(LNX_WM_Window *window, Vec2F32 pos, B32 *out_is_in_
|
||||
{
|
||||
moveresize_code = _NET_WM_MOVERESIZE_SIZE_BOTTOM;
|
||||
}
|
||||
else
|
||||
{
|
||||
in_non_client_area = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -807,7 +811,7 @@ wm_get_events(Arena *arena, B32 wait)
|
||||
set_mouse_cursor = 1;
|
||||
if(window->custom_border)
|
||||
{
|
||||
B32 in_client_area;
|
||||
B32 in_client_area = 0;
|
||||
int moveresize_code = lnx_moveresize_code_from_pos(window, e->pos, &in_client_area);
|
||||
if(!in_client_area)
|
||||
{
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
//~ rjf: Decide On Backend
|
||||
|
||||
#if !defined(R_OPENGL_LINUX_BACKEND)
|
||||
# define R_OPENGL_LINUX_BACKEND R_OPENGL_LINUX_BACKEND_GLX
|
||||
# define R_OPENGL_LINUX_BACKEND R_OPENGL_LINUX_BACKEND_EGL
|
||||
#endif
|
||||
|
||||
////////////////////////////////
|
||||
|
||||
Reference in new issue
Block a user