Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 398312c6 authored by Alexey Dobriyan's avatar Alexey Dobriyan Committed by Greg Kroah-Hartman
Browse files

perf tools: Fixup get_current_dir_name() compilation



commit 128dbd78bd673f9edbc4413072b23efb6657feb0 upstream.

strdup() prototype doesn't live in stdlib.h .

Add limits.h for PATH_MAX definition as well.

This fixes the build on Android.

Signed-off-by: default avatarAlexey Dobriyan (SK hynix) <adobriyan@gmail.com>
Acked-by: default avatarNamhyung Kim <namhyung@kernel.org>
Link: http://lore.kernel.org/lkml/YRukaQbrgDWhiwGr@localhost.localdomain


Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 393a1aa4
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -3,8 +3,9 @@
//
#ifndef HAVE_GET_CURRENT_DIR_NAME
#include "get_current_dir_name.h"
#include <limits.h>
#include <string.h>
#include <unistd.h>
#include <stdlib.h>

/* Android's 'bionic' library, for one, doesn't have this */