hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cmcc...@apache.org
Subject hadoop git commit: HADOOP-12560: Fix sprintf warnings in {{DomainSocket.c}} introduced by HADOOP-12344 (Mingliang Liu via Colin P. McCabe)
Date Tue, 10 Nov 2015 18:58:42 GMT
Repository: hadoop
Updated Branches:
  refs/heads/branch-2 edd4b2d45 -> 7a47989bc


HADOOP-12560: Fix sprintf warnings in {{DomainSocket.c}} introduced by HADOOP-12344 (Mingliang
Liu via Colin P. McCabe)

(cherry picked from commit 493e8ae55278f2446ba251fc39547e61a4115c52)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/7a47989b
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/7a47989b
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/7a47989b

Branch: refs/heads/branch-2
Commit: 7a47989bc968252bba93429a09b7e78c441ee995
Parents: edd4b2d
Author: Colin Patrick Mccabe <cmccabe@cloudera.com>
Authored: Tue Nov 10 10:54:52 2015 -0800
Committer: Colin Patrick Mccabe <cmccabe@cloudera.com>
Committed: Tue Nov 10 10:58:36 2015 -0800

----------------------------------------------------------------------
 hadoop-common-project/hadoop-common/CHANGES.txt   |  3 +++
 .../src/org/apache/hadoop/net/unix/DomainSocket.c | 18 +++++++++---------
 2 files changed, 12 insertions(+), 9 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/7a47989b/hadoop-common-project/hadoop-common/CHANGES.txt
----------------------------------------------------------------------
diff --git a/hadoop-common-project/hadoop-common/CHANGES.txt b/hadoop-common-project/hadoop-common/CHANGES.txt
index c77808e..cffc4fc 100644
--- a/hadoop-common-project/hadoop-common/CHANGES.txt
+++ b/hadoop-common-project/hadoop-common/CHANGES.txt
@@ -712,6 +712,9 @@ Release 2.8.0 - UNRELEASED
 
     HADOOP-12482. Race condition in JMX cache update. (Tony Wu via lei)
 
+    HADOOP-12560: Fix sprintf warnings in {{DomainSocket.c}} introduced by
+    HADOOP-12344 (Mingliang Liu via Colin P. McCabe)
+
   OPTIMIZATIONS
 
     HADOOP-12051. ProtobufRpcEngine.invoke() should use Exception.toString()

http://git-wip-us.apache.org/repos/asf/hadoop/blob/7a47989b/hadoop-common-project/hadoop-common/src/main/native/src/org/apache/hadoop/net/unix/DomainSocket.c
----------------------------------------------------------------------
diff --git a/hadoop-common-project/hadoop-common/src/main/native/src/org/apache/hadoop/net/unix/DomainSocket.c
b/hadoop-common-project/hadoop-common/src/main/native/src/org/apache/hadoop/net/unix/DomainSocket.c
index c653a27..221782d 100644
--- a/hadoop-common-project/hadoop-common/src/main/native/src/org/apache/hadoop/net/unix/DomainSocket.c
+++ b/hadoop-common-project/hadoop-common/src/main/native/src/org/apache/hadoop/net/unix/DomainSocket.c
@@ -341,37 +341,37 @@ JNIEnv *env, jclass clazz, jobject jstr, jint skipComponents)
     mode = st.st_mode & 0777;
     if (mode & 0002) {
       jthr = newIOException(env, "The path component: '%s' in '%s' has "
-         "permissions 0%03o uid %ld and gid %ld. "
+         "permissions 0%03o uid %"PRId64" and gid %"PRId64". "
          "It is not protected because it "
          "is world-writable. This might help: 'chmod o-w %s'. "
          "For more information: "
          "https://wiki.apache.org/hadoop/SocketPathSecurity",
-         check, path, mode, (long long)st.st_uid, (long long)st.st_gid, check);
+         check, path, mode, (int64_t)st.st_uid, (int64_t)st.st_gid, check);
       goto done;
     }
     if ((mode & 0020) && (st.st_gid != 0)) {
       jthr = newIOException(env, "The path component: '%s' in '%s' has "
-         "permissions 0%03o uid %ld and gid %ld. "
+         "permissions 0%03o uid %"PRId64" and gid %"PRId64". "
          "It is not protected because it "
          "is group-writable and not owned by root. "
          "This might help: 'chmod g-w %s' or 'chown root %s'. "
          "For more information: "
          "https://wiki.apache.org/hadoop/SocketPathSecurity",
-         check, path, mode, (long long)st.st_uid, (long long)st.st_gid,
+         check, path, mode, (int64_t)st.st_uid, (int64_t)st.st_gid,
          check, check);
       goto done;
     }
     if ((mode & 0200) && (st.st_uid != 0) && (st.st_uid != uid)) {
       jthr = newIOException(env, "The path component: '%s' in '%s' has "
-         "permissions 0%03o uid %ld and gid %ld. "
+         "permissions 0%03o uid %"PRId64" and gid %"PRId64". "
          "It is not protected because it "
          "is owned by a user who is not root "
-         "and not the effective user: '%ld'. "
-         "This might help: 'chown root %s' or 'chown %ld %s'. "
+         "and not the effective user: '%"PRId64"'. "
+         "This might help: 'chown root %s' or 'chown %"PRId64" %s'. "
          "For more information: "
          "https://wiki.apache.org/hadoop/SocketPathSecurity",
-         check, path, mode, (long long)st.st_uid, (long long)st.st_gid,
-         (long long)uid, check, (long long)uid, check);
+         check, path, mode, (int64_t)st.st_uid, (int64_t)st.st_gid,
+         (int64_t)uid, check, (int64_t)uid, check);
       goto done;
     }
   }


Mime
View raw message