[SCM] Samba Shared Repository - branch v3-3-test updated - release-3-2-0pre2-4229-ga1dd4fc

Tim Prouty tprouty at samba.org
Tue Oct 7 17:49:56 GMT 2008


The branch, v3-3-test has been updated
       via  a1dd4fc647340238eac10d411f531e37dba901b9 (commit)
      from  2334140b6c22f52930b7d168d6f26c18032d5efc (commit)

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-3-test


- Log -----------------------------------------------------------------
commit a1dd4fc647340238eac10d411f531e37dba901b9
Author: Tim Prouty <tim.prouty at isilon.com>
Date:   Tue Oct 7 09:47:46 2008 -0700

    Fixed build warning "passing arg from incompatible pointer type"
    
    The fix explicitly makes the conversion from timeval to time_t using the
    existing time utility functions.
    
    Compiling modules/vfs_smb_traffic_analyzer.c
    modules/vfs_smb_traffic_analyzer.c: In function `smb_traffic_analyzer_send_data':
    modules/vfs_smb_traffic_analyzer.c:173: warning: passing arg 1 of `localtime' from incompatible pointer type

-----------------------------------------------------------------------

Summary of changes:
 source/modules/vfs_smb_traffic_analyzer.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source/modules/vfs_smb_traffic_analyzer.c b/source/modules/vfs_smb_traffic_analyzer.c
index ff61768..9b4c1b3 100644
--- a/source/modules/vfs_smb_traffic_analyzer.c
+++ b/source/modules/vfs_smb_traffic_analyzer.c
@@ -156,6 +156,7 @@ static void smb_traffic_analyzer_send_data(vfs_handle_struct *handle,
 {
 	struct refcounted_sock *rf_sock = NULL;
 	struct timeval tv;
+	time_t tv_sec;
 	struct tm *tm = NULL;
 	int seconds;
 	char *str = NULL;
@@ -170,7 +171,8 @@ static void smb_traffic_analyzer_send_data(vfs_handle_struct *handle,
 	}
 
 	GetTimeOfDay(&tv);
-	tm=localtime(&tv.tv_sec);
+	tv_sec = convert_timespec_to_time_t(convert_timeval_to_timespec(tv));
+	tm = localtime(&tv_sec);
 	if (!tm) {
 		return;
 	}


-- 
Samba Shared Repository


More information about the samba-cvs mailing list