Andrew V. Samoilov
2c8db2c43d
* smbfs.c (smbfs_open_readwrite): Comment out flags games,
...
it is cli_open() headache.
2004-10-25 08:15:19 +00:00
Andrew V. Samoilov
e4d7245a11
* undelfs.c (undelfs_open): Use g_try_malloc() instead
...
of g_malloc().
* smbfs.c (smbfs_send): Don't account negative "ret".
2004-10-16 19:19:27 +00:00
Andrew V. Samoilov
320caad2e1
* smbfs.c (smbfs_forget): Check smbfs_connections[i].cli
...
to avoid possible segmentation fault. Close
https://savannah.gnu.org/bugs/index.php?func=detailitem&item_id=8974
2004-09-28 09:30:53 +00:00
Andrew V. Samoilov
c060826178
* direntry.c (vfs_s_free_entry): g_free handles NULL argument too,
...
no need for the comparison.
* extfs.c (extfs_free_archive): Likewise.
(extfs_open_archive): Likewise.
(extfs_read_archive): Likewise.
(extfs_remove_entry): Likewise.
(extfs_free_entry): Likewise.
* fish.c (fish_open_archive): Likewise.
(fish_archive_same): Likewise.
* ftpfs.c (ftpfs_split_url): Likewise.
* local.c (local_closedir): Likewise.
* mcserv.c (close_handle): Likewise.
* smbfs.c (smbfs_free_bucket): Likewise.
* tar.c (tar_read_header): Likewise.
* undelfs.c (undelfs_shutdown): Likewise.
* vfs.c (vfs_shut): Likewise.
2004-09-24 23:00:18 +00:00
Roland Illig
8335c0fab3
* smbfs.c (smbfs_init): Added a cast to avoid compiler warning.
2004-09-18 14:41:42 +00:00
Andrew V. Samoilov
fc3bf048e9
* local.c (local_readlink): Make "size" size_t.
...
* direntry.c (vfs_s_readlink): Revert last changes. Make "size"
size_t.
* sfs.c (sfs_readlink): Reformat function.
* smbfs.c (smbfs_readlink): Reformat function.
2004-09-02 14:12:21 +00:00
Andrew V. Samoilov
81e4bdfe72
smbfs.c (smbfs_open_readwrite): Implement O_APPEND via smbfs_lseek().
2004-08-26 19:51:38 +00:00
Andrew V. Samoilov
a2d1d4e8dc
* direntry.c: Use g_strlcpy instead strncpy for fix buffer overrun
...
* extfs.c: Likewise.
* mcfs.c: Likewise.
* smbfs.c: Likewise.
* utilvfs.c: Likewise.
2004-08-26 08:47:50 +00:00
Roland Illig
388442cf0c
smbfs.c: Modified smbfs_convert_path based on a patch sent by Andrew V. Samoilov. Adjusted the calls to smbfs_convert_path. Simplified string handling by using free_after from src/util.h. Fixed one memory leak and one accidental modification.
2004-08-19 12:05:54 +00:00
Roland Illig
94d1dea0b9
Added more const-ness. Avoided name collisions by shadowing.
2004-08-17 11:18:47 +00:00
Roland Illig
1105b8e941
Splittet the vfs.h header into a user's part (vfs.h) and an implementor's part (vfs-impl.h).
2004-08-16 23:25:49 +00:00
Roland Illig
b17b1ac213
Const-ified the rest of the vfs_class methods.
2004-08-16 22:15:28 +00:00
Roland Illig
e0bf99d516
Made the path argument to vfs->{chmod,chown,utime} constant.
2004-08-16 21:36:39 +00:00
Roland Illig
dc70d154db
Made the buf argument to vfs->write constant.
2004-08-16 21:16:54 +00:00
Roland Illig
789e5e9bcb
Made the path argument to vfs->[l]stat constant. Created a new memory leak, which will be fixed soon.
2004-08-16 20:26:42 +00:00
Roland Illig
a50890b1a4
Added missing function prototypes. Added const-ness. Fixed an "empty-then-clause" bug.
2004-08-16 16:59:43 +00:00
Roland Illig
db3f21b702
Added a typedef for a function. Added more const-ness to the function arguments.
2004-08-16 16:34:11 +00:00
Pavel Roskin
05e6a61834
* smbfs.c (smbfs_reconnect): Revert changes in a translated
...
message.
2004-01-28 00:01:30 +00:00
Pavel Roskin
30c4bd1b6d
* vfs.h: Constify chdir() and opendir() methods. Adjust all
...
dependencies.
* vfs.c (mc_chdir): Constify, eliminate protection against
broken implementations of chdir() method.
(mc_opendir): Constify.
2003-11-13 08:29:37 +00:00
Pavel Roskin
4eab382dba
* gc.c: Make getid(), nothingisopen() and free() methods
...
optional. Eliminate trivial implementations.
(vfs_getid): New function - safe wrapper around getid(). Use
it everywhere.
(vfs_ncs_getid): Remove dead code, inprove readability.
2003-11-08 23:53:00 +00:00
Pavel Roskin
7d16d65e35
* vfs.h: Constify some arguments for many functions.
...
* xdirentry.h: Likewise. Adjust all dependencies.
2003-10-28 02:10:33 +00:00
Pavel Roskin
5bc20fd294
* *.c: Rename functions that don't have an a prefix indicating
...
what file they are defined in. This simplifies debugging.
2003-10-28 00:57:02 +00:00
Pavel Roskin
211ce16fac
* wtools.c: Merge mc_message() and message() into one background
...
safe function message(). Fix all callers.
2003-10-26 04:47:20 +00:00
Pavel Roskin
50045218ab
Remove unneeded includes in ../src
2003-10-25 21:34:57 +00:00
Pavel Roskin
2d33b5047e
* background.c: Replace all message stubs with a new function
...
mc_message(). Protect against strlen(MSG_ERROR). Adjust all
dependencies.
2003-10-25 19:54:24 +00:00
Pavel Roskin
52844a3092
* vfs.h: Rename commands for mc_ctl() and mc_setctl() to make it
...
clear which function they are used with.
* vfs.c (mc_ctl): Change last argument to (void*).
(mc_set): Likewise.
Adjust all dependencies.
2003-10-16 16:12:19 +00:00
Pavel Roskin
72c64a60e2
* extfs.c: Switch to self-registration.
...
* mcfs.c: Likewise.
* sfs.c: Likewise.
* smbfs.c: Likewise.
* undelfs.c: Likewise.
* vfs.s (_vfs_add_noncurrent_stamps): Temporary disable code
that uses vfs_extfs_ops.
(vfs_file_is_smb): Remove.
2003-10-12 22:25:53 +00:00
Pavel Roskin
00b57fd4bf
* vfs.h: Remove typedef vfs, it's too ambiguous. Massive
...
changes to use struct vfs_class instead.
2003-10-12 00:24:00 +00:00
Pavel Roskin
1d6e00faf0
* vfs.h: Introduce new VFS flags instead of the old unused ones.
...
* vfs.c (vfs_file_class_flags): New function.
(vfs_file_is_ftp): Eliminate.
(vfs_file_is_smb): Likewise.
(vfs_file_is_local): Likewise.
(vfs_current_is_local): Use new VFSF_LOCAL flag.
2003-10-11 08:21:16 +00:00
Pavel Roskin
091023c37a
* undelfs.c (undelfs_get_path): Constify first argument.
...
* vfs.h (struct vfs_class): Constify path. Fix all dependencies.
2003-10-11 07:20:53 +00:00
Andrew V. Samoilov
6f188101cf
* smbfs.c (open_readwrite): New function to replace open_read()
...
and open_write(). Use cli_close() if cli_qfileinfo() or
cli_getattrE() fail.
(smbfs_open): Use open_readwrite(). Free remote_handle if
open_readwrite() fails.
2003-04-03 10:45:03 +00:00
Andrew V. Samoilov
cbe4a1adf4
* smbfs.c (smbfs_lseek): Backport from Samba 2.2.7 Suite.
...
(fake_server_stat): Warning fix for AIX. Reformat function.
(fake_share_stat): Likewise.
(smbfs_mkdir): Likewise.
2003-02-19 12:56:03 +00:00
Pavel Roskin
4d4294fdb4
* smbfs.c (smbfs_nothingisopen): Warning fix for 64-bit systems.
...
(smbfs_free): Likewise.
2003-01-24 20:55:55 +00:00
Andrew V. Samoilov
f5dc73aa71
* smbfs.c: Resurrect and use myumask for generated permissions.
2002-12-20 18:16:45 +00:00
Andrew V. Samoilov
6b0df00830
* smbfs.c (new_dir_entry): Initialize st_ino, so recursive directory
...
copying is possible now.
2002-11-07 14:49:13 +00:00
Andrew V. Samoilov
f4a0b6e40b
* smbfs.c (fake_share_stat): Make sure share exists by
...
smbfs_get_path() and fill buf with realistic data
if current_share_info is NULL. Reformat function.
(smbfs_get_path): Add const qualifier to path.
2002-10-11 15:29:55 +00:00
Andrew V. Samoilov
e751871446
(smbfs_stat): Don't write to path.
2002-10-10 10:04:41 +00:00
Andrew V. Samoilov
872e77eb1d
* smbfs.c: Allow username in URL (/#smb:[user@]machine) and
...
reformat changed functions.
(smbfs_get_host_and_username): Fix comment.
(smbfs_fill_names): Add username@ before hostname.
(smbfs_open_link): Use IPC$ if share is empty.
(smbfs_get_path): Pass remote_path to smbfs_open_link().
(smbfs_stat): Copy username@ to server_url if passed.
2002-10-09 13:18:10 +00:00
Andrew V. Samoilov
3d95a5fa29
* smbfs.c: Don't define BOOL_DEFINED to fix compilation on SunOS 5.8.
2002-10-07 10:05:36 +00:00
Pavel Roskin
da7e82d253
Global removal of RCS Id: flags.
2002-09-26 23:13:45 +00:00
Andrew V. Samoilov
e98d979a69
* smbfs.c: Undef USE_NCURSES - no needs to include *curces.h.
...
(smbfs_loaddir): Fix warning.
2002-09-24 15:26:55 +00:00
Andrew V. Samoilov
3bab5199aa
Fix some possible NULL dereferences.
2002-09-13 11:29:35 +00:00
Andrew V. Samoilov
6a6fb355df
* smbfs.c (smbfs_set_debugf): New function to specify logfile.
...
* smbfs.h: Declare smbfs_set_debugf().
2002-09-13 09:46:33 +00:00
Andrew V. Samoilov
14c3f90d2f
* smbfs.c (statfile_helper): Merge with loaddir_helper().
...
(get_remote_stat): Use loaddir_helper(). Care about
single_entry instead of eliminated statfile_helper().
2002-09-12 06:25:21 +00:00
Andrew V. Samoilov
8e1af10110
* samba/libsmb/clientgen.c (cli_NetServerEnum): Add void*
...
parameter to (*fn)() and void *state parameter.
(cli_list): Likewise.
(cli_RNetShareEnum): Likewise. Return int.
* samba/include/proto.h: Adjust declarations.
* smbfs.c: Adjust all helpers and dependencies.
From Samba patchsets.
2002-09-11 16:43:41 +00:00
Andrew V. Samoilov
1f06c11cc6
* smbfs.c (statfile_helper): Remove write permissions if file
...
has readonly attribute. Add execute permissions for directory.
Reformat whole function.
2002-09-11 15:35:55 +00:00
Andrew V. Samoilov
996dd893b5
* smbfs.c (loaddir_helper): Remove write permissions if file
...
has readonly attribute. Add execute permissions for directory.
Reformat whole function.
(server_browsing_helper): Add execute permissions. Reformat.
(browsing_helper): Likewise.
2002-09-11 12:53:58 +00:00
Pavel Roskin
83d0b9a9d6
Global replacement for two quasi-english strings from vfs/smbfs.c.
2002-09-11 04:06:25 +00:00
Andrew V. Samoilov
47f1a6a51b
* smbfs.c (smbfs_close): Return -1 if cli->outbuf is NULL and
...
set my_errno to EINVAL - temporary fix. Reformat function.
2002-09-02 10:54:22 +00:00
Andrew V. Samoilov
019c16b047
* samba/param/loadparm.c: Add global_scope variable.
...
(parm_table): Add netbios scope parameter.
* samba/lib/util.c: Remove scope variable. Use global_scope instead.
* samba/libsmb/nmblib.c (make_nmb_name): Remove scope parameter and
use global_scope instead.
* samba/libsmb/namequery.c: Adjust make_nmb_name() calls.
* samba/include/proto.h: Adjust make_nmb_name() declaration.
From samba 2.0.7 patchset.
* samba/param/loadparm.c (lp_adduser_script): Commented out.
(lp_deluser_script): Likewise.
(lp_add_printer): Likewise.
(lp_add_one_printer): Likewise.
* samba/lib/util.c (reduce_name): Likewise.
(transfer_file): Likewise.
* smbfs.c (smbfs_do_connect): Adjust make_nmb_name() calls.
2002-09-01 06:51:24 +00:00