From f17773c64f300909b30db49be3d2ec12ebf2674f Mon Sep 17 00:00:00 2001 From: yellows8 Date: Tue, 1 Oct 2019 20:50:09 -0400 Subject: [PATCH] Check for nullptr before copying to out_data in serviceDispatchImpl. --- nx/include/switch/sf/service.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nx/include/switch/sf/service.h b/nx/include/switch/sf/service.h index 2bf0ba8e..55e268e8 100644 --- a/nx/include/switch/sf/service.h +++ b/nx/include/switch/sf/service.h @@ -439,7 +439,7 @@ NX_INLINE Result serviceDispatchImpl( disp.out_num_objects, disp.out_objects, disp.out_handle_attrs, disp.out_handles); - if (R_SUCCEEDED(rc) && out_data_size) + if (R_SUCCEEDED(rc) && out_data && out_data_size) __builtin_memcpy(out_data, out, out_data_size); }