]> granicus.if.org Git - strace/commit
quotactl: add xlat styles support
authorShankara Pailoor <shankarapailoor@gmail.com>
Wed, 19 Dec 2018 13:01:40 +0000 (05:01 -0800)
committerDmitry V. Levin <ldv@altlinux.org>
Mon, 24 Dec 2018 10:19:24 +0000 (10:19 +0000)
commit1448070a00bdc3f5f8ac4ce67fd02b3f114c915b
tree7301cffb00210bb8d3010bf90b1844a752abf98f
parentb967e34d70895b799d16f5d45a9a5228d7eb73a3
quotactl: add xlat styles support

* quota.c (print_qcmd): New function.
(SYS_FUNC(quotactl)): Use it to print the quotactl command.
* tests/quotactl.c (print_dqinfo, print_dqfmt): Handle XLAT_RAW
and XLAT_VERBOSE.
(QUOTA_STR, QUOTA_ID_STR, QUOTA_STR_INVALID): New macros.
(gen_quotacmd, gen_quotaid): New functions.
(main): Use them.
* tests/quotactl-Xabbrev.c: New file.
* tests/quotactl-Xraw.c: Likewise.
* tests/quotactl-Xverbose.c: Likewise.
* tests/gen_tests.in (quotactl-Xabbrev, quotactl-Xraw,
quotactl-Xverbose): New tests.
* tests/pure_executables.list: Add quotactl-Xabbrev, quotactl-Xraw,
and quotactl-Xverbose.
* tests/.gitignore: Likewise.

Co-Authored-by: Dmitry V. Levin <ldv@altlinux.org>
quota.c
tests/.gitignore
tests/gen_tests.in
tests/pure_executables.list
tests/quotactl-Xabbrev.c [new file with mode: 0644]
tests/quotactl-Xraw.c [new file with mode: 0644]
tests/quotactl-Xverbose.c [new file with mode: 0644]
tests/quotactl.c