]> git.ipfire.org Git - thirdparty/dracut.git/commit
refactor(dracut-install): do not call dirname() directly
authorMarcos Mello <marcosfrm@gmail.com>
Sun, 24 Jul 2022 19:49:17 +0000 (16:49 -0300)
committerJóhann B. Guðmundsson <johannbg@gmail.com>
Fri, 12 Aug 2022 11:45:59 +0000 (11:45 +0000)
commit7f2b09339c063279f736f6d4f079f6dd7ed10577
tree19a82cb21fd712eddd10dae3cf19d8c6df59a09c
parentb72d0d7f9be53c1ad04f132daf0297aff7581e9c
refactor(dracut-install): do not call dirname() directly

Avoid its horrible API. Borrow dirname_malloc() from systemd:

https://github.com/systemd/systemd/blob/v251/src/basic/path-util.c#L775
https://github.com/systemd/systemd/blob/v251/src/basic/path-util.h#L150

(licence is LGPLv2.1 or later)
src/install/dracut-install.c
src/install/util.c
src/install/util.h