shared/loop-util: drop inline function with one use

This commit is contained in:
Zbigniew Jędrzejewski-Szmek 2019-12-06 10:56:49 +01:00
parent ba5450f411
commit 6b2a8b80b4
2 changed files with 1 additions and 5 deletions

View File

@ -163,7 +163,7 @@ int loop_device_make_by_path(const char *path, int open_flags, uint32_t loop_fla
if (fd < 0)
return -errno;
return loop_device_make(fd, open_flags, loop_flags, ret);
return loop_device_make_full(fd, open_flags, 0, 0, loop_flags, ret);
}
LoopDevice* loop_device_unref(LoopDevice *d) {

View File

@ -15,10 +15,6 @@ struct LoopDevice {
};
int loop_device_make_full(int fd, int open_flags, uint64_t offset, uint64_t size, uint32_t loop_flags, LoopDevice **ret);
static inline int loop_device_make(int fd, int open_flags, uint32_t loop_flags, LoopDevice **ret) {
return loop_device_make_full(fd, open_flags, 0, 0, loop_flags, ret);
}
int loop_device_make_by_path(const char *path, int open_flags, uint32_t loop_flags, LoopDevice **ret);
int loop_device_open(const char *loop_path, int open_flags, LoopDevice **ret);