occlum/demos/gdb_support/sample.c
LI Qing bd56504b20 Add GDB support for apps running upon Occlum
Please see the "gdb_support" in demos to find out how to
use GDB to debug your apps running upon Occlum.
2020-02-14 07:52:45 +00:00

19 lines
262 B
C

#include <stdio.h>
// GDB will stop here
int divide_by_zero(int num) {
int result;
int zero = 0;
result = num / zero;
return result;
}
int main() {
int ret;
printf("Start to calculate\n");
ret = divide_by_zero(1);
return 0;
}