diff options
author | Stefan Metzmacher <metze@samba.org> | 2004-08-04 13:23:35 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:57:47 -0500 |
commit | c5fbb6f23c2d399c7510bc552cdb1a27b1ef66a8 (patch) | |
tree | 6fccf75601681c68afca5dd9c6b840de44f7f31c /source4/utils/net_time.c | |
parent | a0cb701b6fac6e75da691e239cd0407b9269533a (diff) | |
download | samba-c5fbb6f23c2d399c7510bc552cdb1a27b1ef66a8.tar.gz samba-c5fbb6f23c2d399c7510bc552cdb1a27b1ef66a8.tar.bz2 samba-c5fbb6f23c2d399c7510bc552cdb1a27b1ef66a8.zip |
r1654: rename cli_ -> smbcli_
rename CLI_ -> SMBCLI_
metze
(This used to be commit 8441750fd9427dd6fe477f27e603821b4026f038)
Diffstat (limited to 'source4/utils/net_time.c')
-rw-r--r-- | source4/utils/net_time.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/source4/utils/net_time.c b/source4/utils/net_time.c index 4e6ce2336d..f7220c9424 100644 --- a/source4/utils/net_time.c +++ b/source4/utils/net_time.c @@ -24,16 +24,16 @@ /* return the time on a server. This does not require any authentication */ -static time_t cli_servertime(const char *host, struct in_addr *ip, int *zone) +static time_t smbcli_servertime(const char *host, struct in_addr *ip, int *zone) { struct nmb_name calling, called; time_t ret = 0; - struct cli_state *cli = NULL; + struct smbcli_state *cli = NULL; - cli = cli_initialise(NULL); + cli = smbcli_initialise(NULL); if (!cli) goto done; - if (!cli_connect(cli, host, ip)) { + if (!smbcli_connect(cli, host, ip)) { fprintf(stderr,"Can't contact server\n"); goto done; } @@ -45,11 +45,11 @@ static time_t cli_servertime(const char *host, struct in_addr *ip, int *zone) make_nmb_name(&called, "*SMBSERVER", 0x20); } - if (!cli_session_request(cli, &calling, &called)) { + if (!smbcli_session_request(cli, &calling, &called)) { fprintf(stderr,"Session request failed\n"); goto done; } - if (!cli_negprot(cli)) { + if (!smbcli_negprot(cli)) { fprintf(stderr,"Protocol negotiation failed\n"); goto done; } @@ -58,14 +58,14 @@ static time_t cli_servertime(const char *host, struct in_addr *ip, int *zone) if (zone) *zone = cli->serverzone; done: - if (cli) cli_shutdown(cli); + if (cli) smbcli_shutdown(cli); return ret; } /* find the servers time on the opt_host host */ static time_t nettime(int *zone) { - return cli_servertime(opt_host, opt_have_ip? &opt_dest_ip : NULL, zone); + return smbcli_servertime(opt_host, opt_have_ip? &opt_dest_ip : NULL, zone); } /* return a time as a string ready to be passed to /bin/date */ @@ -172,7 +172,7 @@ int net_time(int argc, const char **argv) } /* default - print the time */ - t = cli_servertime(opt_host, opt_have_ip? &opt_dest_ip : NULL, NULL); + t = smbcli_servertime(opt_host, opt_have_ip? &opt_dest_ip : NULL, NULL); if (t == 0) return -1; d_printf("%s", ctime(&t)); |