Commit Graph

1421 Commits

Author SHA1 Message Date
Enrico Weigelt, metux IT service
d579bb7877 Ticket #1789: Removed obsolete checks for setuid(), getuid(), etc
Removed obsolete checks for setuid(), getuid(), etc

Signed-off-by: Enrico Weigelt <weigelt@metux.de>
2009-12-15 18:13:40 +03:00
Enrico Weigelt, metux IT service
551ac003a4 Ticket #1788: remove obsolete checks for <pwd.h> and <grp.h>
remove obsolete checks for <pwd.h> and <grp.h>

Signed-off-by: Enrico Weigelt, metux IT service <weigelt@metux.de>
2009-12-15 18:00:02 +03:00
Enrico Weigelt, metux IT service
2b4f8103ce Ticket #1786: remove obsolete check for <sys/wait.h>
remove obsolete check for <sys/wait.h>
    This file is C standard, so no explicit check necessary.

Signed-off-by: Enrico Weigelt <weigelt@metux.de>
2009-12-15 17:20:36 +03:00
Slava Zanko
c0ebaf5bd3 Ticket #1796: FTPFS does not work in active mode.
Fix commit for work in passive ftp-mode.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-12-15 13:26:03 +02:00
Enrico Weigelt, metux IT service
e9b01c6400 Ticket #1787: remove obsolete checks for <stdlib.h> 2009-12-13 05:29:35 +01:00
Enrico Weigelt, metux IT service
294f58e85d Ticket #1783: remove own declaration of bzero() 2009-12-12 21:06:40 +01:00
Enrico Weigelt, metux IT service
c99db81350 Ticket #1782: Remove own declaration of ftruncate() 2009-12-12 21:01:46 +01:00
Enrico Weigelt, metux IT service
996029c3e6 Ticket #1784: remove own declaration of strdup 2009-12-12 20:59:08 +01:00
Slava Zanko
3a9f0024da Ticket #1450: FISH: timestamps don't show correctly
Fixed forgotten variable substitution: now substitute value of variable instread of variable name

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-12-07 17:59:44 +02:00
Slava Zanko
d712d2638e Ticket #1796: FTPFS does not work in active mode
Fixed error with active mode of ftpfs.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-12-02 16:05:26 +02:00
Slava Zanko
4fc08a729e Fix broken filenames and timestamps on really poor busybox devices.
This good patch for FISH'ing to devices like my D-Link-500T :)

'busybox ls -lan'  and native 'ls -lan' is different. For example

$ busybox ls -lan /dev

drwxr-xr-x    1 0  0  0     0      0 Jan  1  1970 .
drwxrwxrwx    1 0  0  0     0      68 Dec 12  2007 ..
crw-------    1 0  0  0     0 8,   0 Jan  1  1970 .devfsd
crw-------    1 0  0  0     0 5,   1 Jan  1 12:01 console
crw-rw-rw-    1 0  0  0     0 1,   7 Jan  1  1970 full
...

and
$ ls -lan /dev
drwxr-xr-x  12 0   0     4340 Ноя 20 09:33 .
drwxr-xr-x  23 0   0     4096 Июл 29  2004 ..
crw-rw----+  1 0   0  14,  12 Июл 29  2004 adsp
crw-------   1 0   0  10, 175 Июл 29  2004 agpgart
crw-rw----+  1 0   0  14,   4 Июл 29  2004 audio

output of 'busybox ls' have two additional columns, therefore
names on filesystem shows like:
/1 12:00 proc
/1 1970 dev
/12 2007 bin
/12 2007 etc
/12 2007 lib
/12 2007 sbin
...

This patch will fix it behavior.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-12-01 21:49:12 +02:00
Alexander Moiseenko
11928eeff0 Ticket #1450: FISH: timestamps don't show correctly
Test case:
1) Make FISH-connect to some host;
2) sort files by modification time;
3) will see older files (from previous year) as new files

For check, connect to same host and enter in command line:

ls -lt

Thanks for bugreport to Alexander Glyzov.

Fix issue:
Because first part of FISH-ls script is Perl script.
But localtime function returns dates like:
Fri Sep 18 10:40:28 2009

But in utilvfs.c is written: So both year and time is not allowed.
This commit fixed write format of date.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-12-01 21:49:12 +02:00
Slava Zanko
e7ed071be7 /vfs/extfs/rpm wrapper is totally rewritten.
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-11-23 10:16:28 +02:00
Andrew Borodin
d53630b800 Drop srpm VFS at all. rpm VFS is used instead.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-11-23 10:16:28 +02:00
Arkadiusz Miśkiewicz
03fd0a6cd0 Ticket #1590: single rpm script that also does srpm job.
Use rpm script for srpm job, too.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-11-23 10:16:28 +02:00
Andrew Borodin
f84917a188 Fixed skip of empty directories in the root of cpio archive.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-11-19 20:34:25 +03:00
Andrew Borodin
698385bdd0 Ticket #1732: cpio VFS skips empty directories in the root of archive
Initial step: some optimization and type accuracy.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-11-19 20:34:25 +03:00
Slava Zanko
4f6c5e7811 Ticket #1708: ftp permissions
Some FTP-servers don't have chmon support (or don't able to change permissions in some cases).

This commit will add "ignore_ftp_chattr_errors" section into config file.

Now default behavior: ignore FTP errors related to chmod operations.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-11-12 11:06:52 +02:00
Slava Zanko
d58af17cb8 Changed include 'glib.h' to 'global.h' because global.h file has some things for
backward compatibility with glib (eg. including 'glibcompat.h')

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-11-09 13:49:57 +01:00
Enrico Weigelt, metux IT service
e0b3247c50 vfs/mcserv.c: fixed variable name clashes and missing includes 2009-11-09 13:49:56 +01:00
Enrico Weigelt, metux IT service
cd2f7bd24a vfs/undelfs.c: Fixed variable name clashes 2009-11-09 13:49:56 +01:00
Enrico Weigelt, metux IT service
f3370ca9e5 vfs/vfs-impl.h: fixed missing includes 2009-11-09 13:49:56 +01:00
Enrico Weigelt, metux IT service
6ca8086ab1 vfs/utilvfs.h: fixed missing includes 2009-11-09 13:49:56 +01:00
Enrico Weigelt, metux IT service
91a5df442f Dropping non-strftime() support and fixing -Werror problem
Problem:

a) when running ./configure, strftime() and other functions cannot be
   properly detected, since autoconf generates crappy test code, which
   at least fails when warnings are treated as errors (gcc: -Werror).

b) strtime() is standard since C89, so we can simply expect it to exists
   (if there's *really* some acient box out there breaking mc build,
   it's libc/toolchain should be fixed ;-p)

Solution:

Remove the checks for strftime() and all workarounds
2009-11-09 13:49:56 +01:00
Slava Zanko
51f10b3038 Cleanup of code for compile with new warnings options for compilator
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-10-30 20:36:48 +02:00
Andrew Borodin
91a4598b54 Ticket #1755: code cleanup before 4.7.0-pre4 release.
Free some variables allocated at MC startup.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-10-30 14:41:03 +02:00
Slava Zanko
e7c6d59e63 Code cleanup for compile with new CFLAGS value.
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-10-28 13:37:40 +02:00
Denys Vlasenko
710d88cf3c Ticket #1725: Do not abort on broken .cpio file
For some reason, mc aborts if .cpio magic as wrong.
This trivial patch makes mc handle it gracefully.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-10-22 10:43:13 +03:00
Ilia Maslakov
91be46a861 Ticket #1726 (AI_ADDRCONFIG fix)
fixed undeclared AI_ADDRCONFIG under uclibc <0.9.29

Signed-off-by: Ilia Maslakov <il.smind@google.com>
2009-10-20 18:13:20 +00:00
Slava Zanko
f589410ced Ticket #1729: extfs: fail copying into arhive
Test case:
 * create any zip-archive (or take exists)
 * run mc
 * enter into archive
 * try to copy any files inside archive.

Fix issue: Try to open temporarry file twice: with O_CREATE flag; and without O_CREATE and with O_TRUNC flag
Also, created extfs_chown() function for avoid chown-related warnings.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-10-20 13:04:30 +03:00
Slava Zanko
91248f05bd Ticket #1712: VFS fix for mc.
Fix segfaults in various cases while browsing various VFSs.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-10-15 09:39:26 +03:00
Slava Zanko
3b05057818 Ticket #1607: undelfs check broken in configure.ac
Fix running onfigure with '--disable-vfs-undelfs' option.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-10-15 09:34:29 +03:00
Yuri Fil
c5fd4aef8e Ticket #1681: extfs for .cab
Added ability for work with Microsoft CAB archives.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-10-07 13:14:24 +03:00
Slava Zanko
dd94068a62 Ticket #1649: Prepare for prerelease mc-4.7.0-pre3 (code cleanup)
Try to compile with
{{{
make CFLAGS="-Wall -Werror -Wno-long-long -Wwrite-strings"
}}}

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-09-30 16:42:11 +03:00
Slava Zanko
ff6cd52e53 Ticket #44: More functionally u7z.
* automatically search of 7z or 7za utility
* fixed calculate of EXFNAME file name.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-09-24 14:14:46 +03:00
Slava Zanko
bd95f71a6b Some little bugfixies for xz and lzma archives:
* Increase number of reading butes by one for better analyzation of compression type.
* Add recognize lzma archive by extention.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-09-16 02:05:06 +03:00
Denys Vlasenko
e064bd60df De-inline a few functions which are large
...or not-so-large but nevertheless
contain more than one function call,
or contain loops, or contain if's and at least one
function call, or contain largish objects on stack.

In my experience, in those cases the code size
growth is big enough to not inline stuff.

I guess some of the really big functions
are defined inline because they have, or had in the past,
just one callsite.

But for a few years gcc already does it automatically,
no need to do it by hand and risk code size explosion
when later during code evolution another callsite
is created. This optimization by hand is simply
no longer needed.

Anyway, here is the code size difference:

   text    data     bss     dec     hex filename
 572337   17944  177820  768101   bb865 mc.t5/.obj/src/mc
 567697   17944  177820  763461   ba645 mc.t6/.obj/src/mc

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Signed-off-by: Sergei Trofimovich <slyfox@inbox.ru>
2009-08-31 07:12:59 +03:00
Daniel Borca
ad42905ecf Ticket #1477: incorrect detection of compressed patchfs
UseCase:
 * rename any patch file into patch_file.lzma_tar.patch.gz for example
 * try to enter into renamed file (press Enter key on a file in panel)
 * You'll see error message 'sh: lzma: command not found'

Fix issue:
 * Add -b key into call of 'file' utility (to avoid filename in output)
 * better parse 'file -b' output

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-08-24 17:41:36 +03:00
Sergei Trofimovich
b933da347e vfs/fish.c: removed unused variable
Signed-off-by: Sergei Trofimovich <slyfox@inbox.ru>
2009-08-24 09:31:26 +04:00
Andrew Borodin
179e516c2a VFS: moved vfs_translate_url() declaration to the public scope.
Fixed missed includes.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-24 09:31:26 +04:00
Andrew Borodin
f2e6817363 Ticket #1414: small refactoring before major modifications.
Fixed missed includes.
Fised widget_set_size() declaration.
Moved default widget callback (default_proc()) from dialog.[ch] to widget.[ch].

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-17 15:54:39 +04:00
Jindrich Novy
b1b3be843c Ticket #121 (support IPv6).
Implemented support of IPv6 protocol in FTP connections.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-08-13 00:32:26 +03:00
Andrew Borodin
05b89b3bab VFS: removed unnedeed includes of tty/tty.h header.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2009-08-12 21:23:55 +04:00
Slava Zanko
ce54d07561 Fix include paths in some source files
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-08-12 21:23:13 +04:00
Andrew Borodin
fb51cb8241 Use TTY function names instead of #define's. 2009-08-12 21:23:12 +04:00
Andrew Borodin
f3730bdc41 Initial step to move TTY layer of MC to separate library. 2009-08-12 21:19:20 +04:00
Sergei Trofimovich
5f1ad860b7 Ticket #1527: heap corruption detected on large filenames
Fix bug, introduced in 27fbf91c28
commit. Really allocate 'dirent + NAME_MAX + 1', instead of
sizeof(void*) + NAME_MAX + 1.

Signed-off-by: Sergei Trofimovich <st@anti-virus.by>
2009-08-12 12:37:32 +03:00
Patrick Winnertz
c313396a45 Ticket #1501
* place every operation into a if clause, so that every failure of the
     operations is reported.
    * Place chown/chmod into if conditions to check if the commands where
      successfull or not on fish.
    * Added one more argument to the #CHOWN line

    Signed-off-by: Patrick Winnertz <winnie@debian.org>
2009-08-10 07:10:42 +00:00
Stan. S. Krupoderov
96c0dc08d8 Ticket #1485: iso9660 extfs does not handle certain isos
extfs/iso9660.in: add suport UCS l1, and fix ageinst new isoinfo

    Original author: dborca

Signed-off-by: Stan. S. Krupoderov <pashelper@gmail.com>
2009-08-09 16:27:27 +04:00
Slava Zanko
c78c4a555a Ticket #1467 (Portability: fix bashism in vfs/extfs/u7z)
Fixed bashism in 'mcu7zip_rm' and 'mcu7zip_rmdir' functions.
 * Use 'printf' instread of 'echo -e'
 * stderor redirected to /dev/null

Thanks to narcan.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-08-05 16:37:36 +03:00