]> git.ipfire.org Git - thirdparty/util-linux.git/commit
libsmartcols: don't print empty output on empty table in JSON
authorKarel Zak <kzak@redhat.com>
Mon, 7 Sep 2020 09:52:13 +0000 (11:52 +0200)
committerKarel Zak <kzak@redhat.com>
Fri, 13 Nov 2020 11:00:15 +0000 (12:00 +0100)
commit0bb705cae18f327b7cb748c48a8202854b5b93d9
treeb6b7e0357534f77fe09a21f70f0986b8389ecafa
parent95c706c9c2ae2d7e1f095713dae68c7f9cc2462d
libsmartcols: don't print empty output on empty table in JSON

old version:
 $ findmnt --json --type foo
 $

new version:
 $ findmnt --json --type foo
 {
    "filesystems": [
    ]
 }

Addresses: https://github.com/karelzak/util-linux/issues/1136
Signed-off-by: Karel Zak <kzak@redhat.com>
libsmartcols/src/print-api.c