From a7b6dd4f2f0583e24dff139f6f8e6a707585456d Mon Sep 17 00:00:00 2001 From: Volker Lendecke Date: Fri, 4 Sep 2015 16:40:25 +0200 Subject: [PATCH] libsmbclient: Fix 32-bit problems Signed-off-by: Volker Lendecke Reviewed-by: Michael Adam Autobuild-User(master): Michael Adam Autobuild-Date(master): Mon Sep 7 15:13:08 CEST 2015 on sn-devel-104 --- examples/libsmbclient/teststat.c | 16 ++++++++-------- examples/libsmbclient/teststat2.c | 16 ++++++++-------- examples/libsmbclient/testutime.c | 16 ++++++++-------- 3 files changed, 24 insertions(+), 24 deletions(-) diff --git a/examples/libsmbclient/teststat.c b/examples/libsmbclient/teststat.c index f36639eab7b3..4084fd08e61f 100644 --- a/examples/libsmbclient/teststat.c +++ b/examples/libsmbclient/teststat.c @@ -47,10 +47,10 @@ int main(int argc, char * argv[]) return 1; } - printf("\nSAMBA\n mtime:%lu/%s ctime:%lu/%s atime:%lu/%s\n", - st.st_mtime, ctime_r(&st.st_mtime, m_time), - st.st_ctime, ctime_r(&st.st_ctime, c_time), - st.st_atime, ctime_r(&st.st_atime, a_time)); + printf("\nSAMBA\n mtime:%lld/%s ctime:%lld/%s atime:%lld/%s\n", + (long long)st.st_mtime, ctime_r(&st.st_mtime, m_time), + (long long)st.st_ctime, ctime_r(&st.st_ctime, c_time), + (long long)st.st_atime, ctime_r(&st.st_atime, a_time)); if (pLocalPath != NULL) { @@ -60,10 +60,10 @@ int main(int argc, char * argv[]) return 1; } - printf("LOCAL\n mtime:%lu/%s ctime:%lu/%s atime:%lu/%s\n", - st.st_mtime, ctime_r(&st.st_mtime, m_time), - st.st_ctime, ctime_r(&st.st_ctime, c_time), - st.st_atime, ctime_r(&st.st_atime, a_time)); + printf("LOCAL\n mtime:%lld/%s ctime:%lld/%s atime:%lld/%s\n", + (long long)st.st_mtime, ctime_r(&st.st_mtime, m_time), + (long long)st.st_ctime, ctime_r(&st.st_ctime, c_time), + (long long)st.st_atime, ctime_r(&st.st_atime, a_time)); } return 0; diff --git a/examples/libsmbclient/teststat2.c b/examples/libsmbclient/teststat2.c index fcd3e309351a..963cd2709d27 100644 --- a/examples/libsmbclient/teststat2.c +++ b/examples/libsmbclient/teststat2.c @@ -47,10 +47,10 @@ static int gettime(const char * pUrl, return 1; } - printf("SAMBA\n mtime:%lu/%s ctime:%lu/%s atime:%lu/%s\n", - st.st_mtime, ctime_r(&st.st_mtime, m_time), - st.st_ctime, ctime_r(&st.st_ctime, c_time), - st.st_atime, ctime_r(&st.st_atime, a_time)); + printf("SAMBA\n mtime:%lld/%s ctime:%lld/%s atime:%lld/%s\n", + (long long)st.st_mtime, ctime_r(&st.st_mtime, m_time), + (long long)st.st_ctime, ctime_r(&st.st_ctime, c_time), + (long long)st.st_atime, ctime_r(&st.st_atime, a_time)); /* check the stat on this file */ @@ -60,10 +60,10 @@ static int gettime(const char * pUrl, return 1; } - printf("LOCAL\n mtime:%lu/%s ctime:%lu/%s atime:%lu/%s\n", - st.st_mtime, ctime_r(&st.st_mtime, m_time), - st.st_ctime, ctime_r(&st.st_ctime, c_time), - st.st_atime, ctime_r(&st.st_atime, a_time)); + printf("LOCAL\n mtime:%lld/%s ctime:%lld/%s atime:%lld/%s\n", + (long long)st.st_mtime, ctime_r(&st.st_mtime, m_time), + (long long)st.st_ctime, ctime_r(&st.st_ctime, c_time), + (long long)st.st_atime, ctime_r(&st.st_atime, a_time)); return 0; diff --git a/examples/libsmbclient/testutime.c b/examples/libsmbclient/testutime.c index 2b3c40b61b59..cdbcfec31647 100644 --- a/examples/libsmbclient/testutime.c +++ b/examples/libsmbclient/testutime.c @@ -47,10 +47,10 @@ int main(int argc, char * argv[]) return 1; } - printf("Before\n mtime:%lu/%s ctime:%lu/%s atime:%lu/%s\n", - st.st_mtime, ctime_r(&st.st_mtime, m_time), - st.st_ctime, ctime_r(&st.st_ctime, c_time), - st.st_atime, ctime_r(&st.st_atime, a_time)); + printf("Before\n mtime:%lld/%s ctime:%lld/%s atime:%lld/%s\n", + (long long)st.st_mtime, ctime_r(&st.st_mtime, m_time), + (long long)st.st_ctime, ctime_r(&st.st_ctime, c_time), + (long long)st.st_atime, ctime_r(&st.st_atime, a_time)); utimbuf.actime = t; /* unchangable (wont change) */ utimbuf.modtime = t; /* this one should succeed */ @@ -66,10 +66,10 @@ int main(int argc, char * argv[]) return 1; } - printf("After\n mtime:%lu/%s ctime:%lu/%s atime:%lu/%s\n", - st.st_mtime, ctime_r(&st.st_mtime, m_time), - st.st_ctime, ctime_r(&st.st_ctime, c_time), - st.st_atime, ctime_r(&st.st_atime, a_time)); + printf("After\n mtime:%lld/%s ctime:%lld/%s atime:%lld/%s\n", + (long long)st.st_mtime, ctime_r(&st.st_mtime, m_time), + (long long)st.st_ctime, ctime_r(&st.st_ctime, c_time), + (long long)st.st_atime, ctime_r(&st.st_atime, a_time)); return 0; } -- 2.34.1