Commit a12db19e authored by Colin Ian King's avatar Colin Ian King Committed by Sasha Goldshtein

libbpf: fix build warning on setns (#1246)

The macro _GNU_SOURCE should be defined to pick up the function
declaration for setns.  Fixes build warning:

"src/cc/libbpf.c:482:7: warning: implicit declaration of
 function 'setns' [-Wimplicit-function-declaration]
   if (setns(target_fd, CLONE_NEWNS)) {"
Signed-off-by: default avatarColin Ian King <colin.king@canonical.com>
parent 34cbbfe5
......@@ -13,6 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#define _GNU_SOURCE
#include <arpa/inet.h>
#include <errno.h>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment