summaryrefslogtreecommitdiffstats
path: root/stream/stream_smb.c
diff options
context:
space:
mode:
authordiego <diego@b3059339-0415-0410-9bf9-f77b7e298cf2>2009-05-13 02:58:57 +0000
committerdiego <diego@b3059339-0415-0410-9bf9-f77b7e298cf2>2009-05-13 02:58:57 +0000
commit6e9cbdc10448203e7c8b2de41447442fcc9f7bae (patch)
tree0ed465592509105fdbeab27fc12ddbb2e3590aa5 /stream/stream_smb.c
parenteafe5b7517bbf408ae1ffc936a3abe2313c3b334 (diff)
downloadmpv-6e9cbdc10448203e7c8b2de41447442fcc9f7bae.tar.bz2
mpv-6e9cbdc10448203e7c8b2de41447442fcc9f7bae.tar.xz
whitespace cosmetics: Remove all trailing whitespace.
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@29305 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'stream/stream_smb.c')
-rw-r--r--stream/stream_smb.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/stream/stream_smb.c b/stream/stream_smb.c
index 370e599db5..17ba027687 100644
--- a/stream/stream_smb.c
+++ b/stream/stream_smb.c
@@ -35,23 +35,23 @@ static void smb_auth_fn(const char *server, const char *share,
char *password, int pwmaxlen)
{
char temp[128];
-
- strcpy(temp, "LAN");
+
+ strcpy(temp, "LAN");
if (temp[strlen(temp) - 1] == 0x0a)
temp[strlen(temp) - 1] = 0x00;
-
+
if (temp[0]) strncpy(workgroup, temp, wgmaxlen - 1);
-
- strcpy(temp, smb_username);
+
+ strcpy(temp, smb_username);
if (temp[strlen(temp) - 1] == 0x0a)
temp[strlen(temp) - 1] = 0x00;
-
+
if (temp[0]) strncpy(username, temp, unmaxlen - 1);
-
- strcpy(temp, smb_password);
+
+ strcpy(temp, smb_password);
if (temp[strlen(temp) - 1] == 0x0a)
temp[strlen(temp) - 1] = 0x00;
-
+
if (temp[0]) strncpy(password, temp, pwmaxlen - 1);
}
@@ -98,9 +98,9 @@ static int open_f (stream_t *stream, int mode, void *opts, int* file_format) {
mode_t m = 0;
off_t len;
int fd, err;
-
+
filename = stream->url;
-
+
if(mode == STREAM_READ)
m = O_RDONLY;
else if (mode == STREAM_WRITE) //who's gonna do that ?
@@ -110,27 +110,27 @@ static int open_f (stream_t *stream, int mode, void *opts, int* file_format) {
m_struct_free (&stream_opts, opts);
return STREAM_UNSUPPORTED;
}
-
+
if(!filename) {
mp_msg(MSGT_OPEN,MSGL_ERR, "[smb] Bad url\n");
m_struct_free(&stream_opts, opts);
return STREAM_ERROR;
}
-
+
err = smbc_init(smb_auth_fn, 1);
if (err < 0) {
mp_msg(MSGT_OPEN,MSGL_ERR,MSGTR_SMBInitError,err);
m_struct_free(&stream_opts, opts);
return STREAM_ERROR;
}
-
+
fd = smbc_open(filename, m,0644);
- if (fd < 0) {
+ if (fd < 0) {
mp_msg(MSGT_OPEN,MSGL_ERR,MSGTR_SMBFileNotFound, filename);
m_struct_free(&stream_opts, opts);
return STREAM_ERROR;
}
-
+
stream->flags = mode;
len = 0;
if(mode == STREAM_READ) {
@@ -148,7 +148,7 @@ static int open_f (stream_t *stream, int mode, void *opts, int* file_format) {
stream->write_buffer = write_buffer;
stream->close = close_f;
stream->control = control;
-
+
m_struct_free(&stream_opts, opts);
return STREAM_OK;
}