Commit Graph

13824 Commits

Author SHA1 Message Date
Andrew Borodin
9d735e02f1 Merge branch '3749_vfs_blksize'
* 3749_vfs_blksize:
  (vfs_adjust_stat): new VFS API, currently used to calculate st_blocks.
  Clarify usage of st_rdev. Use it if HAVE_STRUCT_STAT_ST_RDEV is defined.
  ftpfs: define st_blksize as equal to 64K.
  fishfs: define st_blksize as equal to 64K.
  Modify VFS APIs.
  tarfs: define st_blksize as equal to 8K.
  sftpfs: (sftpfs_fix_filename): refactoring: return length of result.
  sftpfs: minor optimization.
  sftpfs: define st_blksize and st_blocks.
  (vfs_s_default_stat): define st_blksize and st_blocks explicitly.
  Clarify usage of st_blocks. Use it if HAVE_STRUCT_STAT_ST_BLOCKS is defined.
  Ticket #3749: fix segfault in VFS if block size is not set.
2017-01-11 14:53:02 +03:00
Andrew Borodin
aae43d362f (vfs_adjust_stat): new VFS API, currently used to calculate st_blocks.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-11 14:52:35 +03:00
Andrew Borodin
bf40acf420 Clarify usage of st_rdev. Use it if HAVE_STRUCT_STAT_ST_RDEV is defined.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-11 14:52:35 +03:00
Andrew Borodin
d1c2c2d47e ftpfs: define st_blksize as equal to 64K.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-11 14:52:35 +03:00
Andrew Borodin
21fd0c3fec fishfs: define st_blksize as equal to 64K.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-11 14:52:35 +03:00
Andrew Borodin
061d60b82f Modify VFS APIs.
* vfs_s_stat: make public.
  * vfs_s_lstat: likewise.
  * vfs_s_fstat: likewise.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-11 14:52:35 +03:00
Andrew Borodin
560ca526bd tarfs: define st_blksize as equal to 8K.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-11 14:52:35 +03:00
Andrew Borodin
110f4eae60 sftpfs: (sftpfs_fix_filename): refactoring: return length of result.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-11 14:52:35 +03:00
Andrew Borodin
ffe49251f7 sftpfs: minor optimization.
* (sftpfs_opendir): get rid of extra calculation of file name length.
  * (sftpfs_open_file): likewise.
  * (sftpfs_readlink): likewise.
  * (sftpfs_symlink): likewise.
  * (sftpfs_rename): likewise.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-11 14:52:35 +03:00
Andrew Borodin
95556224a6 sftpfs: define st_blksize and st_blocks.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-11 14:52:35 +03:00
Andrew Borodin
a8a8e85279 (vfs_s_default_stat): define st_blksize and st_blocks explicitly.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-11 14:52:35 +03:00
Andrew Borodin
7e4a59e8d6 Clarify usage of st_blocks. Use it if HAVE_STRUCT_STAT_ST_BLOCKS is defined.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-11 14:52:35 +03:00
Andrew Borodin
8dabd9ac2a Ticket #3749: fix segfault in VFS if block size is not set.
Initial commit: clarify usage of st_blksize. Use it if
HAVE_STRUCT_STAT_ST_BLKSIZE is defined.

Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-11 14:52:35 +03:00
Yury V. Zaytsev
94787407f1 Merge branch '3747_hp48_extfs' 2017-01-01 17:30:09 +04:00
Mooffie
8b65c36d3f Ticket #3747: extfs: hp48: make the code more readable.
Whitespace tweaking here. There's no change in the code itself except for
using '%c' in the first printf too, to make it like the second printf.

Signed-off-by: Yury V. Zaytsev <yury@shurup.com>
2017-01-01 17:29:59 +04:00
Mooffie
501a3122ff Ticket #3747: extfs: hp48: fix float truncation.
Some printf implementations can't process with %d anything other than integers.

We solve this by re-using the awk snippet for this purpose. This makes
hp48_retsize() unecessary. And hp48_retdir() too.

(The "case" statement was left unindented to, hopefully, not affect diff's
output much. This aesthetic issue will be fixed in a following patch.)

Signed-off-by: Yury V. Zaytsev <yury@shurup.com>
2017-01-01 17:29:59 +04:00
Andrew Borodin
55f4dce8ac PULL_REQUEST_TEMPLATE.md: use https for m-c.o.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2017-01-01 09:39:06 +03:00
Yury V. Zaytsev
569569d1e4 maint: add GitHub pull request template trying to direct contributors to Trac
Signed-off-by: Yury V. Zaytsev <yury@shurup.com>
2016-12-30 17:45:06 +04:00
Yury V. Zaytsev
67b3d64957 Merge branch '3708_tests_usability' 2016-12-27 16:47:33 +04:00
Mooffie
4a559344fb Ticket #3708: fix usability problems with --enable-tests
Signed-off-by: Mooffie <mooffie@gmail.com>
Signed-off-by: Yury V. Zaytsev <yury@shurup.com>
2016-12-27 16:46:38 +04:00
Yury V. Zaytsev
f40caa3e71 Merge branch '3729_vfs_date_fixes' 2016-12-25 10:06:37 +04:00
Yury V. Zaytsev
940fab955c maint: shorten commit hash if git describe fails
Signed-off-by: Yury V. Zaytsev <yury@shurup.com>
2016-12-25 10:06:23 +04:00
Mooffie
d376f0ca43 extfs: hp48: add tests. 2016-12-25 10:06:23 +04:00
Mooffie
4557ee3c7a extfs: hp48: make it testable. 2016-12-25 10:06:23 +04:00
Mooffie
c91476ac4a Ticket #3729: extfs: hp48: fix date format.
Use "MM-DD-YYYY hh:mm" instead of "Mon DD YYYY hh:mm".

Note: we assign to $NOW at the top-level, not inside hp48_parser(), because the
communication is slow and we don't want each recursive call to hp48_parser() to
potentially print a different time.
2016-12-25 10:06:23 +04:00
Mooffie
019ab5c012 extfs: hp48: misc fixes.
Two bugs fixed:

* "printf -rw-r--r--" made printf complain about invalid option (although
  changing it to "printf -- -rw-r--r-" is possible, we don't know how portble
  this is).

* Quotes around $INPUT defeat the purpose of the function calls (botched in
  commit 61b4642af4).
2016-12-25 10:06:23 +04:00
Mooffie
4d04aa40b0 extfs: hp48: documentation: explain the reply to the DIRECTORY command.
It was not at all easy to find a sample reply on the internet (the one found
was in a screenshot actually), so we record it here.
2016-12-25 10:06:23 +04:00
Mooffie
644682ad2c extfs: uarc: add tests. 2016-12-25 10:06:23 +04:00
Mooffie
22846550d3 extfs: uarc: make it testable. 2016-12-25 10:06:23 +04:00
Mooffie
61eb5cca37 Ticket #3729: extfs: uarc: fix date format.
Use "MM-DD-YYYY hh:mm" instead of "Mon DD YYYY hh:mm".
2016-12-25 10:06:23 +04:00
Mooffie
0e4e80cf79 extfs: uace: add tests. 2016-12-25 10:06:23 +04:00
Mooffie
057ba6d73a extfs: uace: make it testable. 2016-12-25 10:06:22 +04:00
Mooffie
5225a1d21b extfs: uace: documentation: clarify versions issue. 2016-12-25 10:06:22 +04:00
Mooffie
08a8621fc5 extfs: uace: print the correct file size.
As a comment in that file notes: 3'rd column is the compressed size, 4'th
column is the actual size.
2016-12-25 10:06:22 +04:00
Mooffie
105501ba9c Ticket #3729: extfs: uace: fix date format.
Use "MM-DD-YYYY hh:mm" instead of "Mon DD YYYY hh:mm".
2016-12-25 10:06:22 +04:00
Andrew Borodin
4a6fb3b534 Merge branch '3575_nanoseconds'
* 3575_nanoseconds:
  FISH VFS: generate timestamps with nanosecond precision for touch.
  (fish_utime): avoid buffer overflow: allocate buffer for command dynamically.
  Ticket #3575: preserve timestamps with nanosecond precisions during file copy
2016-12-25 08:47:47 +03:00
Andrey Gursky
0075944f1e FISH VFS: generate timestamps with nanosecond precision for touch.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-25 08:46:10 +03:00
Andrew Borodin
53a1d52ed9 (fish_utime): avoid buffer overflow: allocate buffer for command dynamically.
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-25 08:46:10 +03:00
Andrey Gursky
4c418047b2 Ticket #3575: preserve timestamps with nanosecond precisions during file copy
MC truncates timestamps during file copy and drops sub-second precision.

Make use of utimensat(), introduced in Linux kernel 2.6.22 (and since
2.6.26 compatible with POSIX-1.2008).

Signed-off-by: Andrey Gursky <andrey.gursky@e-mail.ua>
Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
2016-12-25 08:46:10 +03:00
Yury V. Zaytsev
9f47eecc91 Merge branch '3744_u7z_tests' 2016-12-24 15:30:50 +04:00
Mooffie
d4ec872f37 Ticket #3744: extfs: u7z: add tests. 2016-12-24 09:58:53 +04:00
Mooffie
fad265c5bd Ticket #3744: extfs: u7z: make it testable. 2016-12-24 09:58:53 +04:00
Yury V. Zaytsev
12dbd957c0 Merge branch '2707_extfs_u7z' 2016-12-24 09:46:13 +04:00
Mooffie
f84c14bbce Ticket #2707: extfs: u7z: print() cleanup.
AWK's print() already writes OFS between expressions.
2016-12-24 09:45:59 +04:00
Mooffie
052bdec1ee Ticket #2707: extfs: u7z: sed portability.
'\s' is not portable.
2016-12-24 09:45:59 +04:00
Mooffie
5c3e999845 Ticket #2707: extfs: u7z: handle missing size.
The uncompressed size may be missing in 7z's output (gods know why). We use the
compressed size in this case.
2016-12-24 09:45:58 +04:00
Mooffie
02051d6090 Ticket #2707: extfs: u7z: make the code more readable. 2016-12-24 09:45:58 +04:00
Yury V. Zaytsev
66ae617b77 extfs: fix whitespace soup in u7z helper
Signed-off-by: Yury V. Zaytsev <yury.zaytsev@moneymeets.com>
2016-12-24 09:45:58 +04:00
Yury V. Zaytsev
6938f1a52d Ticket #2707: extfs u7z helper - fix listing 7z archives w/o datetime info
7z archives can have entries without datetime info (7z a -mtm- ...). Currently,
u7z helper skips these entries. Fix this by detecting them and obtaining
archive file datetime using stat command with fallback to ls -lan.

Signed-off-by: Andreas Mohr <and@gmx.li>
Signed-off-by: Yury V. Zaytsev <yury.zaytsev@moneymeets.com>
2016-12-24 09:45:58 +04:00
Andrew Borodin
f1bc44943c Merge branch '3730_extfs_tester_fix'
* 3730_extfs_tester_fix:
  extfs: urar: don't invoke 'rar' when running under the tester.
  Ticket #3730: extfs: don't run tester on "make check" if disabled.
2016-12-20 13:05:44 +03:00