HADOOP-10966: Merging r1617823 from trunk to branch-2.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1617824 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Arpit Agarwal 2014-08-13 20:04:19 +00:00
parent 93e518be3a
commit 20f40571b8
2 changed files with 7 additions and 0 deletions

View File

@ -137,6 +137,9 @@ Release 2.6.0 - UNRELEASED
HADOOP-10962. Flags for posix_fadvise are not valid in some architectures
(David Villegas via Colin Patrick McCabe)
HADOOP-10966. Hadoop Common native compilation broken in windows.
(David Villegas via Arpit Agarwal)
Release 2.5.0 - UNRELEASED
INCOMPATIBLE CHANGES

View File

@ -176,6 +176,7 @@ static void nioe_deinit(JNIEnv *env) {
* If the value is not known, return the argument unchanged.
*/
static int map_fadvise_flag(jint flag) {
#ifdef HAVE_POSIX_FADVISE
switch(flag) {
case org_apache_hadoop_io_nativeio_NativeIO_POSIX_POSIX_FADV_NORMAL:
return POSIX_FADV_NORMAL;
@ -198,6 +199,9 @@ static int map_fadvise_flag(jint flag) {
default:
return flag;
}
#else
return flag;
#endif
}
/*