Commit Graph

1381 Commits

Author SHA1 Message Date
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
Ilia Maslakov
07c87f2b27 Ticket #366
fix by mike.dld for tarfs dont shows duplicate folders in some tar-files
2009-08-03 21:20:52 +00:00
Ilia Maslakov
3b1070fb3d Ticket #1453 (crash mc on create new file in external editor (S-F4))
fix: crash mc when path is null on create new file in external editor
2009-08-03 15:37:55 +00:00
Patrick Winnertz
bada6849cd Remove unneeded vars in edit/edit.c to avoid compiler warnings
Signed-off-by: Patrick Winnertz <winnie@debian.org>

edit: cleanup: moved variable declaration to begin of block
edit: have_charset: added explicit variable declarations

Signed-off-by: Sergei Trofimovich <slyfox@inbox.ru>

fix not initialized variable 'cw'
fix variables 'cw', 'utf_ch', make more safety algorithm.
2009-07-17 12:00:01 +03:00
Sergei Trofimovich
d54ea1e079 Ticket #1413 (overly quoted escaped pathnames)
> "ls -l \"/%s\" >/dev/null 2>/dev/null\n"
and longstanding one
    > "ls $LSOPT \"/%s\" 2>/dev/null | grep '[cbt]' | (\n"

Fixing again.

Signed-off-by: Sergei Trofimovich <st@anti-virus.by>
2009-07-16 09:40:34 +03:00
Slava Zanko
33c0d6f022 Fixed segfault with fish operations
Reason:
If some directory in fish is a read-only, then mc will crashed

Issue:
In fish_mkdir added additional check if directory was created.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-07-15 13:59:25 +03:00
Slava Zanko
9ee5f318ab Ticket #1395 (Copying to fish is broken)
No any files was copyed into fish.

Issue:
Files was try to create with O_EXCL flag. On fish it's fail
Now for fish flag O_EXCL will dropped.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-07-15 13:59:25 +03:00
Andrew Borodin
68354273a3 Fixed includes.
Added missed includes. Fixed includes after rebase.

Signed-off-by: Andrew Borodin <borodin@borodin.zarya>
2009-06-19 14:36:36 +04:00
Andrew Borodin
9ef324f7bb edit/edit.h: added function prototypes.
edit/editcmd.c: removed include of eregex.h
vfs/vfs-impl.h: removed commented include of <stddef.h>.
2009-06-18 21:08:24 +04:00
Andrew Borodin
26852546b7 vfs/gc.c src/widget.c: removed unneeded #include's.
vfs/vfs-impl.h src/background.h src/charsets.c
src/esc.h src/file.h src/execute.c src/vfsdummy.h: fixed missed #include's.
src/cons.saver.c: include <config.h> unconditionally.
src/complete.c:: fixed #include's.
src/win.h src/win.c: removed unneeded #include's;
check_movement_keys(): fixed type of returned value.
2009-06-18 21:07:10 +04:00
Andrew Borodin
5f61e9aaa4 Fixed missed #include's after rebase to current master. 2009-06-18 21:06:25 +04:00
Enrico Weigelt, metux IT service
b09a107190 further include file fixups 2009-06-18 21:02:29 +04:00
Enrico Weigelt, metux IT service
c7d04dd47a fixed several missing #include's 2009-06-18 21:02:29 +04:00
Slava Zanko
f018970577 Renamed functions shell_escape (to strutils_shell_escape) and shell_unescape (to strutils_shell_unescape)
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-06-12 10:32:00 +03:00
Slava Zanko
5f810602e0 Moved 'escape' and 'unescape' strings functions from src/util.[ch] into src/strescape.[ch]
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-06-12 10:31:59 +03:00
Slava Zanko
f0182a6969 Fix compile mcserv helper
Changes logic in m4 files for more sense of configure options.
Renamed --with-mcfs ro --enable-mcserver
2009-05-27 21:50:02 +03:00
Slava Zanko
abcd23406d remove ChangeLog files from mc tree
Description by Sergei Trofimovich:

GNU ChangeLog? files are result of CVS stupidpity about changeset tracking.
Currently constantly updated ChangeLogs? diverge in different branches and cause collisions(!)
when 'git merge' (almost ANY SINGLE MERGE!).

Major changes can be described in NEWS file, minor changes can be autogenerated via 'git log'/'git shortlog'
and friends (if needed at all).
2009-05-27 14:53:23 +03:00
Slava Zanko
1a899905bd Fix usage of shell_[un]escape functions.
These functions returns newly allocated string, but calling don't freeze correctly allocated memory.
2009-05-27 11:20:48 +03:00
Slava Zanko
0c17219b2a Move global config files from pkg_datadir to sysconfdir
* Also fixed 'make dist' command
 * changed contrib/dist/redhat/mc.spec.in for builds with new dir
2009-05-21 01:01:10 +03:00
Andrew Zabolotny
c6b42a7369 This patch makes VFS a bit faster by replacing GSList with GPtrArray
and using a clever trick to avoid doing list/array searches on every
VFS lookup.

Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-05-20 21:12:38 +03:00
Ilia Maslakov
b29e81556f Rewritten by David Sterba <dave jikos.cz> patchfs.
add xz compress support to David's version.
2009-05-14 13:38:10 +00:00
xgizzmo
24ca27fe30 Added XZ compression support. Signed-off-by: xgizzmo <xgizzmo@slackbuilds.org>
Signed-off-by: Slava Zanko <slavazanko@gmail.com>
2009-05-13 11:35:22 +03:00
Slava Zanko
121ff2965c Merge branch '345_mcfs_build_failure'
* 345_mcfs_build_failure:
  Fixed mcfs build failure (after reorganize M4-autoconf stuff)
2009-05-12 16:27:55 +03:00
Slava Zanko
428ea1b406 Change name of automake constant 'USE_MCFS' to 'ENABLE_VFS_MCFS' 2009-05-11 13:42:49 +03:00
Slava Zanko
ae46a004e9 Fixed mcfs build failure (after reorganize M4-autoconf stuff)
Defined variable WITH_MCFS renamed to ENABLE_VFS_MCFS for more sence
2009-05-11 10:28:57 +03:00
Slava Zanko
2ebdf91079 Merge branch 'm-utf-8'
* m-utf-8: (223 commits)
  Fix wildcard pattern in file select and file find dialogs
  Project builds with option --disable-charsets
  Deleted build-glib1.sh because glib1 don't work with utf-8
  fix building without --enable-charset
  Total replacement to mc_search stuff in all places
  Search engine: if found_len parameter NULL, then mc_search_run don't try to fill them
  src/view.c: Reworked search stuff to usage src/search
  refactoring: rename edit/editcmd_dialog.c:editcmd_dialog__get_search_types_list to
  Search engine: development of hex search complete
  Search engine: remove forgotten debug string and reindent file
  Search engine:
  configure.ac: if present glib-2.14 and higher, libpcre don't linked
  Search engine: now used regexp external engines:
  src/find.c: Fixed core dump if content search pattern no present
  edit/editcmd_dialogs.c: fixed state of search type between dialog window calls
  Find files: checkbox 'Regular expression' for content search now default unchecked
  Find files: changes for usage of new search engine:
  Fix copy of current/opposite path to command line: remove charset info from path
  src/Makefile.am: add some header files to Make-tracking
  Fixed editor menu reloading.
2009-05-07 13:01:01 +03:00
Sergei Trofimovich
3da14e7f8f Merge branch 'mc-4.6'
* mc-4.6:
  fish: chgrp: trac:#336; do not add exceeding quotes (fixed by snizovtsev)
2009-05-02 16:01:13 +03:00
Sergei Trofimovich
027168ce3d fish: chgrp: trac:#336; do not add exceeding quotes (fixed by snizovtsev)
As we pass  correctly(hopefully) escaped file names - all calls
(except forgotten chgrp) were converted to accept unquoted strings.

This patch fixes chgrp.

Signed-off-by: Sergei Trofimovich <slyfox@inbox.ru>
2009-05-02 14:09:07 +03:00
Slava Zanko
10b7bdb361 Project now build with:
make CFLAGS="-ansi -pedantic -Wall -Wextra -Werror"

WARNING! Builds wuthout samba.
2009-04-24 01:47:22 +03:00
Sergei Trofimovich
0d281515a6 warnings fix: sanitized 'write'alike callback prototype (int retval -> ssize_t)
Signed-off-by: Sergei Trofimovich <slyfox@inbox.ru>
2009-04-23 22:20:34 +03:00
Sergei Trofimovich
27fbf91c28 vfs/vfs.c: valgrind: fixed read-of-unallocated memory
Comment snippet:
    We can't just allocate struct dirent as (see man dirent.h)
    struct dirent has VERY nonnaive semantics of allocating
    d_name in it. Moreover, linux's glibc-2.9 allocates dirents _less_,
    than 'sizeof (struct dirent)' making full bitwise (sizeof dirent) copy
    heap corrupter. So, allocate longliving dirent with at least
    (NAME_MAX + 1) for d_name in it.
    Strictly saying resulting dirent is unusable as we don't adjust internal
    structures, holding dirent size. But we don't use it in libc infrastructure.
    TODO: to make simpler homemade dirent-alike structure.

Signed-off-by: Sergei Trofimovich <slyfox@inbox.ru>
2009-04-22 22:15:51 +03:00
Andrew Borodin
dc8150a521 src/strutil.h: created estr_t type for result of charset convertion functions.
Modified descriptions.

src/strutil.c (_str_convert): return value of estr_t type instead of int.
Check coder first. Removed redundant code.
(str_convert): simplified. Changed returned type to estr_t.
(str_nconvet): likewise.
(str_vfs_convert_to): likewise.
(str_vfs_convert_from): likewise. Used symbolic names instead of hardcoded values.
(str_translate_char): likewise.

src/strutil8bit.c (str_8bit_vfs_convert_to): likewise. Made function static.

src/strutilascii.c (str_ascii_vfs_convert_to): likewise.

src/strutilutf8.c: (str_utf8_vfs_convert_to): Used symbolic names
instead of hardcoded values.

src/charsets.c (convert_from_utf_to_current): likewise.
(convert_from_utf_to_current_c): likewise.
(convert_from_8bit_to_utf_c): likewise.
(convert_from_8bit_to_utf_c2): likewise.

src/view.c (view_get_char): likewise.

vfs/vfs.c (_vfs_translate_path): Changed returned type to estr_t.
Used symbolic names instead of hardcoded values.
(vfs_translate_path): likewise.
2009-04-22 20:35:32 +04:00
Slava Zanko
df3926d1c4 Fix show directory and file names in other that system encoding symbolsets (with error of recoding).
Old behaviour: enrties not show, new behaviour: entries show, but marked as broken files if
recoding impossible
2009-04-20 13:09:59 +03:00
Sergei Trofimovich
e88a6bd4d8 vfs/vfs.c: build fix: iconv_t(-1) -> INVALID_CONV
Signed-off-by: Sergei Trofimovich <slyfox@inbox.ru>
2009-04-19 22:11:49 +03:00
Mikhail S. Pobolovets
121e910351 Merge branch '191_extfs_unrar' 2009-04-16 22:50:03 +03:00
Mikhail S. Pobolovets
07584c35c7 Merge branch '190_srpm_support' 2009-04-16 22:31:48 +03:00
Mikhail S. Pobolovets
e0831ebd2e * vfs/extfs/urar.in: If unrar is not aviable then use rar instead
Signed-off-by: Mikhail S. Pobolovets <styx.mp@gmail.com>
2009-04-16 20:41:25 +03:00
Slava Zanko
ac8ae55181 Fix conflicts after rebasing 2009-04-16 13:24:47 +03:00
Slava Zanko
6ecea97973 vfs/vfs.c: Replace str_conv_t to GIConv 2009-04-16 13:14:29 +03:00
Slava Zanko
2ac6b553c6 Rework strutils for usage GString
instread of self-made buffers.
2009-04-16 13:13:58 +03:00
Mikhail S. Pobolovets
1959b42fdc Merge branch '252_doxygen_desc_src'
Conflicts:

	src/file.h

Signed-off-by: Mikhail S. Pobolovets <styx.mp@gmail.com>
2009-04-16 08:26:52 +03:00