Skip to content

Commit a35a0fb

Browse files
committed
HADOOP-7680 TestHardLink fails on Mac OS X, when gnu stat is in path.
git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1290868 13f79535-47bb-0310-9956-ffa450edef68
1 parent 6c7239d commit a35a0fb

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

hadoop-common-project/hadoop-common/CHANGES.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -209,6 +209,9 @@ Release 0.23.2 - UNRELEASED
209209
HADOOP-8057 hadoop-setup-conf.sh not working because of some extra spaces.
210210
(Vinayakumar B via stevel)
211211

212+
HADOOP-7680 TestHardLink fails on Mac OS X, when gnu stat is in path.
213+
(Milind Bhandarkar via stevel)
214+
212215
Release 0.23.1 - 2012-02-17
213216

214217
INCOMPATIBLE CHANGES

hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/HardLink.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ public enum OSType {
6464
//override getLinkCountCommand for the particular Unix variant
6565
//Linux is already set as the default - {"stat","-c%h", null}
6666
if (osType == OSType.OS_TYPE_MAC) {
67-
String[] linkCountCmdTemplate = {"stat","-f%l", null};
67+
String[] linkCountCmdTemplate = {"/usr/bin/stat","-f%l", null};
6868
HardLinkCGUnix.setLinkCountCmdTemplate(linkCountCmdTemplate);
6969
} else if (osType == OSType.OS_TYPE_SOLARIS) {
7070
String[] linkCountCmdTemplate = {"ls","-l", null};

0 commit comments

Comments
 (0)