Commit Graph

122 Commits

Author SHA1 Message Date
Pavel Roskin b9c6a9b3d1 * vfs.h: Remove vfs_uid and vfs_gid. Fix all dependencies. 2002-12-06 02:14:28 +00:00
Pavel Roskin 5cb2ef30f3 Fix duplicate declarations. 2002-11-15 06:38:55 +00:00
Pavel Roskin 6b3a6dd169 * vfs.h [USE_VFS] (mc_setctl): Specify argument types. 2002-11-11 19:25:21 +00:00
Pavel Roskin 3f40a2b274 * vfs.c: Remove unused code.
* vfs.h: Define vfs_uid and vfs_gid as 0, they never change.
2002-11-03 10:24:45 +00:00
Pavel Roskin 7bb1b58274 * vfs.h: Remove tar_gzipped_memlimit.
From Christian Laubscher <christian.laubscher@tiscalinet.ch>
2002-10-13 23:25:57 +00:00
Pavel Roskin ec1b1f9614 Globally replace OS2_NT and _OS_NT with WIN32_NATIVE. 2002-09-10 22:04:11 +00:00
Pavel Roskin 9c04fa4313 * vfs.h: Remove BROKEN_PATHS, it's unused. 2002-09-10 21:51:12 +00:00
Pavel Roskin 8568fc50d9 * Make-alone.am: Get rid of all standalone code, it has been
unmaintained for years.
2002-09-10 21:48:49 +00:00
Pavel Roskin f319f7671f * vfs.h: Declare vfs_timeout and tar_gzipped_memlimit. 2002-08-19 00:59:02 +00:00
Pavel Roskin 37f335b8c0 * vfs.h: Introduce union vfs_dirent to ensure that we have
enough space for the filename.
* extfs.c (s_readdir): Use vfs_dirent.  Avoid strcpy().
2002-08-15 20:29:34 +00:00
Pavel Roskin 11a66b3ffd * vfs.h [!USE_VFS]: Declare mc_setctl as static inline function
to fix warnings.
2002-08-15 01:33:11 +00:00
Pavel Roskin 6ddf5f78ed * vfs.h: Rename URL_DEFAULTANON to URL_ALLOW_ANON.
* utilvfs.c (vfs_split_url): Return NULL as username if
URL_ALLOW_ANON is set and no username is found in the URL,
otherwise use current name.
* ftpfs.c (ftp_split_url): New function - split URL and look up
username and password if needed.
(login_server): Use ftp_split_url().
(archive_same): Likewise.
2002-07-11 23:08:30 +00:00
Pavel Roskin 2acfb89cd4 * tcputil.h: Move use_netrc declaration ...
* vfs.h: ... here.
* ftpfs.c: Implement .netrc support unconditionally.
(lookup_netrc): Make static.
* utilvfs.c: Initialize default_is_netrc.
From Thomas Zajic <zlatko@gmx.at>
2002-07-10 21:26:55 +00:00
Andrew V. Samoilov baf5611b51 * vfs.c (MC_RENAMEOP): Make arguments const.
* vfs.h (mc_rename): Adjust declaration.
* (mc_link): Likewise.
2002-05-13 15:39:22 +00:00
Andrew V. Samoilov 1711c0ab8b * direntry.c (vfs_s_retrieve_file): Use off_t for total
and stat_size.

* vfs.c (vfs_s_resolve_symlink): Use snprintf
instead of sprintf.
(vfs_print_stats): Use off_t for have and need.  Cast
have to double to eliminate negative percent(s).
Fix print_vfs_message string formats.

* vfs.h (vfs_print_stats): Adjust declaration.

* ftpfs.c (file_store): Use off_t for total.
Fix print_vfs_message string format.
2002-02-08 09:42:38 +00:00
Pavel Roskin 6975fdf5e8 * vfs.h: Remove all tricks with system headers, they all should
be in global.h.
* cpio.c: Include utilvfs.h earlier.
* tar.c: Likewise.
2002-01-21 21:26:49 +00:00
Pavel Roskin 14f498cc1a * vfs.h: Include dirent.h only if it's present. 2002-01-21 20:01:44 +00:00
Andrew V. Samoilov aad3bb8314 * vfs.h: Spelled. 2002-01-21 11:10:57 +00:00
Pavel Roskin 50e3625d7d * vfs.h: Remove OS/2 specific code. 2002-01-17 07:32:32 +00:00
Pavel Roskin 353e389689 * vfs.h [!USE_VFS]: Define macros with no effect to an empty
statement "do { } while (0)".
2001-10-01 06:01:13 +00:00
Andrew V. Samoilov c908fc4562 * utilvfs.c, vfs.h (vfs_split_url): Make path parameter const. 2001-08-03 10:12:18 +00:00
Pavel Roskin 820a35758e * vfs/smbfs.c: Rename authinfo to smb_authinfo and
authinfo_get_authinfo_from_user() to vfs_smb_get_authinfo()
and remove their definitions.
* vfs/vfs.h: Declare smb_authinfo and vfs_smb_get_authinfo().
2001-07-15 07:01:41 +00:00
Pavel Roskin 19bf66d5e0 * vfs.h: Don't include <config.h>. 2001-06-26 14:41:31 +00:00
Pavel Roskin 5da3b42969 * ftpfs.c: Declare functions without declarations static. Don't
omit `void' in declarations.
* cpio.c: Likewise.
* direntry.c: Likewise.
* extfs.c: Likewise.
* mcfs.c: Likewise.
* tar.c: Likewise.
* vfs.c: Likewise.
* vfs.h: Likewise.
* mcserv.c: Likewise. Remove unused functions.
2001-06-14 20:08:27 +00:00
Pavel Roskin 22a3755dc0 * util-alone.c: Use indented #error.
* vfs.h: Use indented #warning instead of hiding it from non-gcc
compilers.
2001-06-14 15:26:29 +00:00
Andrew V. Samoilov 4ac1c260e9 * vfs.[ch] (vfs_parse_ls_lga, vfs_parse_filemode): p constified
(vfs_strip_suffix_from_filename): filename constified
(vfs_parse_ls_lga): memory leaking fixed when line can't be parsed,
chomping unified
2001-03-05 06:00:27 +00:00
Pavel Roskin 447597a790 * vfs.h: Include sys/timeb.h if it's present. Include time.h and
sys/time.h as recommended by Autoconf documentation.
* cpio.c: Remove all time-related includes - they are in vfs.h.
* extfs.c: Likewise.
* ftpfs.c: Likewise.
* mcfs.c: Likewise.
* mcserv.c: Likewise.
* tar.c: Likewise.
* util-alone.c: Likewise.
* vfs.c: Likewise. Include xdirentry.h.
2001-02-20 16:55:58 +00:00
Pavel Machek a1225de8b3 Fix problems with stating / of ftp server + NO_LOCALHASH to prevent
podfuk deadlocs
2000-04-16 19:13:00 +00:00
Pavel Machek 0b25d26cf0 2000-02-25 Pavel Machek <pavel@artax.karlin.mff.cuni.cz>
Patch by  Andrew V. Samoilov <sav@bcs.zp.ua>

        * vfs.[ch] (vfs_canon, mc_open, vfs_file_is_local,
          mc_(un)?getlocalcopy): added const qualifier
        (mc_def_getlocalcopy): tempnam() returns malloc()ed buffer,
          so, free() it, not g_free();
        (vfs_canon): prepend filename by cwd when tilde '~' cannot be expanded;
2000-02-25 12:53:06 +00:00
Pavel Machek fff243a9db 2000-02-18 Andrew V. Samoilov <sav@bcs.zp.ua>
* vfs.c (mc_def_getlocalcopy): tempnam() returns malloc()ed buffer,
         so, free() it, not g_free();
       (vfs_canon): prepend filename by cwd when tilde '~' cannot be expanded;
       * vfs.[ch] (vfs_canon, mc_open, vfs_file_is_local,
         mc_(un)?getlocalcopy): added const qualifier
2000-02-24 12:00:30 +00:00
Pavel Machek 5d240399be 2000-02-22 Pavel Machek <pavel@artax.karlin.mff.cuni.cz>
* cpio.c: added. Thanx to Jan Hudec <bulb@centrum.cz>, who wrote
        it using code from tarfs.
2000-02-22 18:21:41 +00:00
Pavel Roskin 36facc201c vfs/vfs.h: use #warning only for gcc. Not all compilers
understand it
src/main.c, src/view.c: #warning's replaced with FIXME's.
They were not for users, but for developers
1999-12-22 04:04:23 +00:00
Pavel Machek 1139602a9b Return value is needed for mc_[un]getlocalcopy. 1999-11-11 14:23:40 +00:00
Norbert Warmuth d836e5a79a 1999-09-19 Andrew V. Samoilov <sav@bcs.zp.ua>
* src/user.c (check_patterns): char* is used instead of char [] in sizeof

* src/util.c (string_perm): prefix named pipes by 'p' and not by `s'


1999-09-19  David Martin <dmartina@usa.net>

* gtkedit/editcmd.c (edit_print_string): Use unsigned char so that
8 bit chars from strftime get displayed when inserting date.

* lib/mc.ext.in: Add entries for bzip2 compressed pages as used in
Mandrake 6.0. The generic entry for bzip2 moved to the end of the
file to avoid interferences. In this one I changed the extension check
to a type check (as used for gzip) which might give problems in some
systems.

* configure.in: Use -Tlatin1 to format man pages when available and
"view" 8 bit chars.


1999-09-19  Norbert Warmuth  <nwarmuth@privat.circular.de>

* gtkedit/edit.h: Include files reordered in order to make it compile with
--with-debug

* gtkedit/editcmd.c (menu_save_mode_cmd): calculate dialog width
dependent on lenght of translated strings to display.

* src/mad.c, mad.h, util.c, util.h: Move mad-functions from util.[ch]
to mad.[ch]

* src/option.c: Include files reordered in order to make it compile with
--with-debug

* src/mad.c (mad_init): New function. Initialize debug FILE pointer to
stderr (moved to a function because not on every system stderr is
a constant).
(mad_set_debug): added const qualifier

* src/main.c (main): call mad_init

* po/*.po: s/defination/definition/

* gnome/Makefile.in ($(MAGICDEV_GENERATED)): Make it compile with $buildir
!= $srcdir.

* vfs/ftpfs.c (ftpfs_set_debug), vfs.h: added const qualifier.

* vfs/mcserv.c: removed definition of mad_strconcat which is also
in mad.c.
1999-09-19 23:09:07 +00:00
Miguel de Icaza 2a8730b21c 1999-06-01 Robert Brady <rwb197@ecs.soton.ac.uk>
* file.c (move_dir_dir): Give an error when an attempt is made to
	move an empty directory into itself.

1999-06-14  Wayne Roberts <wroberts1@cx983858-b.orng1.occa.home.com>

	* vfs/smbfs.c: New file.  Implements the Samba-based file system.

	* vfs/vfs.h: Declare vfs_smbfs_ops, vfs_file_is_smb.

	* vfs/vfs.c (vfs_file_is_smb): implemented.
	(vfs_init) register smbfs.

	* vfs/samba: Incorporate SAMBA source code required for smbfs

1999-05-27  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* Make.common.in (confdir): Define confdir as sysconfdir.  This
	should fix the problem we had with FSSTND distributions.
1999-06-22 19:56:36 +00:00
Norbert Warmuth bfa7724f00 Sun Mar 28 23:39:48 1999 Norbert Warmuth <nwarmuth@privat.circular.de>
* configure.in: Deleted duplicate VFS checks. GNOME_VFS_CHECKS
now contains all VFS checks.

* src/util.c (is_printable): Character 155 is non printable even when
full eight bit output is enabled (on the linux console 155 is
interpreted as "ESC [").

* vfs/vfs.h (vfs_translate_url): Fixed the macro which is used when
compiling without vfs.

* macros/gnome-vfs.m4: Add --with-vfs option. GNOME_VFS_LIBS still needs
to be fixed but that's not a problem because there's no libvfs, yet.
1999-03-29 05:06:50 +00:00
Miguel de Icaza 67f787b786 1999-03-11 Miguel de Icaza <miguel@nuclecu.unam.mx>
* vfs.h: Make it compile in AIX.  Boy do those guys polute the
	name space.
1999-03-11 19:01:53 +00:00
Miguel de Icaza 1370e6c166 Notice: release coming in about 90 minutes.
Miguel.

1999-02-15  Miguel de Icaza  <miguel@nuclecu.unam.mx>

	* gcmd.c (gnome_open_terminal_with_cmd): New routine, based on the
	gnome_open_terminal routine, that will allow the user to specify a
	command to execute (used internally).

	* gaction.c (gmc_edit_filename): Support for the GNOME editor
	environment properties.

	* gdesktop.c (create_desktop_dir): Support GNOME_DESKTOP_DIR
	variable to configure the desktop directory.
1999-02-15 21:19:03 +00:00
Timur Bakeyev bf81009392 Actually commit all my changers. Fear :> 1999-01-20 22:01:11 +00:00
Miguel de Icaza 44f75f14ec 1999-01-18 Miguel de Icaza <miguel@nuclecu.unam.mx>
* vfs.h: The correct thing to use is PATH_SEP and PATH_SEP_STR
1999-01-18 16:55:58 +00:00
Paul Sheer ffd5b11060 DIR_SEP_STRING defined as "/" 1999-01-18 07:52:24 +00:00
Miguel de Icaza efd11d6862 Include sys/time.h in AIX 1999-01-11 19:12:57 +00:00
Miguel de Icaza a7170a4f7a OS2 now uses property defines instead of OS2_NT 1999-01-10 08:55:35 +00:00
Miguel de Icaza ca39a2e6ee Windows NT portability fixes from Ilya.
Added create directory option to gnome menu.
Removed debugging messages

Miguel.
1999-01-08 20:38:27 +00:00
Norbert Warmuth 549fecfff7 Wed Dec 16 06:47:47 1998 Norbert Warmuth <nwarmuth@privat.circular.de>
* screen.c (Xtry_to_select): Don't select a similar file when
"name" can't be found in the panel (when deleting files the
selection jumpped from the deleted "file" to a directory which
started with the same character as "file", annoying).
Strip known vfs suffixes from "name" before trying to select
(I think Timur made this suggestion a few months ago). Know the
vfs is mature enough to do this.

* vfs/vfs.c (vfs_strip_suffix_from_filename): New function which strips
known vfs suffixes from a filename and returns a malloced string
which has to be freed. Possible improvement: strip vfs suffix from
last path component.

* vfs/extfs/*: added "umask 077" to every script.
1998-12-16 06:16:13 +00:00
Pavel Machek 3e1a72d64d Some fixes in src/ part (want_stale_data is now done right) and more
daring code in vfs/ (errors are now reported instead of silently
ignored)
1998-12-09 20:22:53 +00:00
Miguel de Icaza 44caa06a7b Small improvements 1998-12-07 17:08:59 +00:00
Pavel Machek fc5a9c57c2 Small fixes, now fish should actually work. Dropped ELAST hack. 1998-12-07 10:15:17 +00:00
Sebastian Wilhelmi 8b8a943b6e 1998-12-02 Sebastian Wilhelmi <wilhelmi@ira.uka.de>
* fish.c (FISH_OP): changed snprintf to g_snprintf, as glib is
        used anyway.

        * xdirentry.h (LINK_NO_FOLLOW):
        * tar.c (read_header):
        * direntry.c (vfs_s_resolve_symlink):
        (vfs_s_inode_from_path):
        (vfs_s_open): renamed NO_FOLLOW and FOLLOW to LINK_NO_FOLLOW and
        LINK_FOLLOW resp. to avoid problems on solaris, where FOLLOW and
        NO_FOLLOW are defined in an enum.

        * vfs.h (ELAST): define it to 300, if not already defined, thats a
        bad hack, but what can we do....
1998-12-02 13:17:24 +00:00
Timur Bakeyev 9522710547 Fix to not portable error codes in vfs.h. Instead of using existing values,
create new ones - by means ELAST+offset. Maybe, the better way for libvfs..
1998-11-28 23:56:59 +00:00
Pavel Machek 4706638b22 Big merge: fish now uses proper caching, small fixes almost
everywhere. I hope I did not break it too much.
1998-11-21 19:36:01 +00:00
Pavel Machek 5602fc5a1e Fix to make it compile. 1998-11-03 17:24:33 +00:00
Pavel Machek 37e364fe67 BIG changes: tar now uses brand-new direntry.c. Hope it does not hurt
too much.
1998-10-23 08:26:25 +00:00
Miguel de Icaza d6fcd9c2b7 VFS source code cleanup.
MC now depends on glib (currently only the assertions are used).
VFS structure declaration fixes.
Uses the new icon list (it is dog slow, need to fix this tonight at home).
1998-10-14 02:56:18 +00:00
Pavel Machek 29e3c314bf Namespace conflict cleaned up. 1998-10-13 10:45:02 +00:00
Pavel Machek 176dc1f70d static's added, do_reget hack removed 1998-10-12 22:07:53 +00:00
Pavel Machek f6b74c679c Disable BROKEN_PATHS by default. 1998-10-06 13:37:12 +00:00
Pavel Roskin ef0f6d00fc vfs_force_expire() was incorrectly defined in vfs.h 1998-10-01 17:42:05 +00:00
Norbert Warmuth c10ecb8b0f Now gmc, tkmc and mc build one my glibc2 system (builddir != srcdir).
Mon Sep 28 21:55:13 1998  Norbert Warmuth  <nwarmuth@privat.circular.de>

* src/find.c: Changed hotkey of the continue-button (both Chdir and
Continue used `C').

* po/*.po: remade because one msgstr in find.c changed

* src/Makefile.in: search config.status in builddir and not in rootdir,
i.e. make it compile for builddir != srcdir

* vfs/vfs.h (struct vfs): renamed errno to verrno because glibc2
defines errno as macro (#define errno (*__errno_location ()))

* vfs/Makefile.in: search config.status in builddir and not in srcdir/..,
i.e. make it compile for builddir != srcdir
1998-09-28 20:41:28 +00:00
Pavel Machek a92e6f3ea8 Changed license to LGPL, added passing of vfs * (acting as self), so
we can do OOP-like trics.
1998-09-27 19:27:58 +00:00
Tom Tromey 00922504b1 Wed Sep 23 15:09:55 1998 Tom Tromey <tromey@cygnus.com>
* vfs.h (MIN, MAX): Only define if not already defined; glib.h
	also defines them.
1998-09-23 21:24:15 +00:00
Pavel Machek a57c127f2d O_LINEAR option added, tar fixed to handle bzip/bzip2 files correctly. 1998-09-21 09:52:07 +00:00
Pavel Machek 7d12623b27 Cleaned up some warnings. 1998-09-18 14:28:07 +00:00
Pavel Machek ee12728d7d /#ssh: and /#rsh: aliases, ERRNOR() macro 1998-09-18 11:02:04 +00:00
Timur Bakeyev 38d687870f *** empty log message *** 1998-09-14 20:50:11 +00:00
Pavel Machek f45e5aa3fc Adding fish, cleanups, and small updates everywhere to support fish. 1998-09-13 10:40:43 +00:00
Pavel Machek 3d0a91d4a8 Added vfs_uid for use by libvfs.so users (rpc.nfsd)
Added single file filesystem (sfs)
Added vfs_flags so library users can disable selected filesystems
Minor shuffling of functions so garbage collection works for library
1998-08-25 16:00:16 +00:00
Miguel de Icaza 7a7f7a3d85 Integration of Pavel Machek's vfs code split and vfs syntax change.
The VFS code can now be used by other applications (if you compile the
libvfs.a target and link against this).

Syntax has changes internally from the url-like syntax to a new syntax
that does not have ambiguities.  A default conversor for the new syntax
will be provided in the future, also dealing with the user ~/.mc/ext files
is currently in a non-optimal state.

Keep an eye on this mailing list.

Miguel.
1998-05-26 00:53:24 +00:00
Pavel Machek 2ba396f80c My previous patch for subshell.h was incorrect. I'm sorry.
Minor patches for OS2_NT.
Buffer size for pattern expansion was insufficient.
1998-04-08 19:37:06 +00:00
Miguel de Icaza 4e74ed86d0 1998-03-31 Philippe De Muyter <phdm@macqel.be>
* vfs.h: compilation fix for m68k-motorola-sysv
1998-03-31 17:27:11 +00:00
Miguel de Icaza b52d3a73ca Sat Mar 7 14:33:38 1998 Pavel Roskin <pavel@absolute.spb.su>
* src/complete.c: obsolete hack for OS/2 and NT removed.
        Completion works for NT now (not very good)

        * src/main.c: HOME variable is respected by NT and OS/2
        versions. If it is missing, we use LIBDIR on OS2_NT and "/"
        on Unix.

        * src/key.h: SHIFT_PRESSED is set to 0x0010 on NT. This value
        doesn't conflict with definitions for ALT and CTRL, but it is
        SDK-compatible.

        * vfs/vfs.h: Minor changes for OS/2. EMX defines mkdir with
        2 arguments

        * vfs/tcputil,c, vfs/utilvfs.c: signal.h was includes twice.

        * vfs/Makefile.in: undelfs.h is not used and should disapper

        * slang/slos2tty.c: new file, copied from SLang-0.99.38,
        needed for OS/2 port

        * slang/Makefile.in: added slos2tty.c

        * vfs/extfs/README: annoying spell errors corrected

        * src/main.c: --termcap disabled for OS2_NT because it doesn't
        (and cannot) work. ARCH_FLAGS is not needed anymore.

        * src/text.c: most includes removed. Added a warning is someone
        compiles this file with HAVE_X. Improved color scheme for
        consoles with 16 background colors (e.g. OS/2). Hack for OS/2
        removed.

        * src/util.c, src/util.h: STRCOMP and MC_ARCH_FLAGS are moved
        to util.h. It may be useful to use them for filenames' completion
        on OS2_NT
1998-03-07 20:27:44 +00:00
Miguel de Icaza eb6b3842ab Initial revision 1998-02-27 04:54:42 +00:00