diff options
Diffstat (limited to 'logwrapper/logwrapper.c')
-rw-r--r-- | logwrapper/logwrapper.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/logwrapper/logwrapper.c b/logwrapper/logwrapper.c index d0d8d14..9e0385d 100644 --- a/logwrapper/logwrapper.c +++ b/logwrapper/logwrapper.c @@ -14,6 +14,7 @@ * limitations under the License. */ +#include <errno.h> #include <stdio.h> #include <stdlib.h> #include <sys/wait.h> @@ -89,7 +90,8 @@ int main(int argc, char* argv[]) { } if (seg_fault_on_exit) { - *(int *)status = 0; // causes SIGSEGV with fault_address = status + uintptr_t fault_address = (uintptr_t) status; + *(int *) fault_address = 0; // causes SIGSEGV with fault_address = status } return rc; |