Merge pull request #4 from q3k/master

Move definition of _FORTIFY_SOURCE to nsjail.h
This commit is contained in:
robertswiecki 2016-01-20 20:23:02 +01:00
commit 53905ed813
2 changed files with 8 additions and 1 deletions

View File

@ -20,7 +20,7 @@
CC = gcc CC = gcc
CFLAGS += -O2 -g -ggdb -c -std=c11 \ CFLAGS += -O2 -g -ggdb -c -std=c11 \
-D_GNU_SOURCE \ -D_GNU_SOURCE \
-fstack-protector-all -Wformat -Wformat=2 -Wformat-security -fPIE -D_FORTIFY_SOURCE=2 -Wa,--noexecstack \ -fstack-protector-all -Wformat -Wformat=2 -Wformat-security -fPIE -Wa,--noexecstack \
-Wall -Wextra -Werror -Wall -Wextra -Werror
LD = gcc LD = gcc

View File

@ -4,6 +4,7 @@
----------------------------------------- -----------------------------------------
Copyright 2014 Google Inc. All Rights Reserved. Copyright 2014 Google Inc. All Rights Reserved.
Copyright 2016 Sergiusz Bazanski. All Rights Reserved.
Licensed under the Apache License, Version 2.0 (the "License"); Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License. you may not use this file except in compliance with the License.
@ -21,4 +22,10 @@
#ifndef _NSJAIL_H #ifndef _NSJAIL_H
#define _NSJAIL_H #define _NSJAIL_H
#ifdef _FORTIFY_SOURCE
#undef _FORTIFY_SOURCE
#endif /* _FORTIFY_SOURCE */
#define _FORTIFY_SOURCE 2
#endif /* _NSJAIL_H */ #endif /* _NSJAIL_H */