about summary refs log tree commit diff
path: root/frida_mode/test
diff options
context:
space:
mode:
authorYour Name <you@example.com>2021-04-16 07:06:37 +0100
committerYour Name <you@example.com>2021-04-16 10:17:43 +0100
commit950648c513d031b5c829565255a7c157a33ba7c3 (patch)
treed0ec8d2b2bc972092de0595b415d02a6720e4b2b /frida_mode/test
parente41d1183cca02fb4d6398df4fc3e028dfd9c5f72 (diff)
downloadafl++-950648c513d031b5c829565255a7c157a33ba7c3.tar.gz
Changes following code review
Diffstat (limited to 'frida_mode/test')
-rw-r--r--frida_mode/test/testinstr.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/frida_mode/test/testinstr.c b/frida_mode/test/testinstr.c
index 2c3d5144..37d47f91 100644
--- a/frida_mode/test/testinstr.c
+++ b/frida_mode/test/testinstr.c
@@ -78,6 +78,13 @@ int main(int argc, char **argv) {
     }
 
     buf = malloc(len);
+    if (buf == NULL) {
+
+      perror("malloc");
+      break;
+
+    }
+
     n_read = read(fd, buf, len);
     if (n_read != len) {