diff mbox series

btrfs-progs: remove path_cat[3]_out() double declaration

Message ID 3f86146a-d69c-e8c4-d3b4-d9c91d199d81@libero.it (mailing list archive)
State New, archived
Headers show
Series btrfs-progs: remove path_cat[3]_out() double declaration | expand

Commit Message

Goffredo Baroncelli Oct. 23, 2021, 4:40 p.m. UTC
Remove the double declaration of path_cat_out()/path_cat3_out()

The functions
   - path_cat_out()
   - path_cat3_out()
are declared two times in the following header files:
   - common/path-utils.h
   - common/send-utils.h

Remove the double declaration from send-utils.h and add the path-utils.h include file
where needed.

Signed-off-by: Goffredo Baroncelli <kreijack@inwind.it>


--

Comments

Nikolay Borisov Oct. 25, 2021, 6:38 a.m. UTC | #1
On 23.10.21 г. 19:40, Goffredo Baroncelli wrote:
> Remove the double declaration of path_cat_out()/path_cat3_out()
> 
> The functions
>   - path_cat_out()
>   - path_cat3_out()
> are declared two times in the following header files:
>   - common/path-utils.h
>   - common/send-utils.h
> 
> Remove the double declaration from send-utils.h and add the path-utils.h
> include file
> where needed.
> 
> Signed-off-by: Goffredo Baroncelli <kreijack@inwind.it>

Reviewed-by: Nikolay Borisov <nborisov@suse.com>
David Sterba Oct. 25, 2021, 3:13 p.m. UTC | #2
On Sat, Oct 23, 2021 at 06:40:49PM +0200, Goffredo Baroncelli wrote:
> Remove the double declaration of path_cat_out()/path_cat3_out()
> 
> The functions
>    - path_cat_out()
>    - path_cat3_out()
> are declared two times in the following header files:
>    - common/path-utils.h
>    - common/send-utils.h
> 
> Remove the double declaration from send-utils.h and add the path-utils.h include file
> where needed.

Thanks, but the prototypes have been removed a few weeks ago, in
"btrfs-progs: remove unused prototypes from send-utils.h". You've
probably developed this on top of master branch.
Goffredo Baroncelli Oct. 25, 2021, 4:58 p.m. UTC | #3
On 10/25/21 17:13, David Sterba wrote:
> On Sat, Oct 23, 2021 at 06:40:49PM +0200, Goffredo Baroncelli wrote:
>> Remove the double declaration of path_cat_out()/path_cat3_out()
>>
>> The functions
>>     - path_cat_out()
>>     - path_cat3_out()
>> are declared two times in the following header files:
>>     - common/path-utils.h
>>     - common/send-utils.h
>>
>> Remove the double declaration from send-utils.h and add the path-utils.h include file
>> where needed.
> 
> Thanks, but the prototypes have been removed a few weeks ago, in
> "btrfs-progs: remove unused prototypes from send-utils.h". You've
> probably developed this on top of master branch.
> 
Correct, I didn't check in devel...
diff mbox series

Patch

diff --git a/cmds/receive-dump.c b/cmds/receive-dump.c
index 058e8918..e8862165 100644
--- a/cmds/receive-dump.c
+++ b/cmds/receive-dump.c
@@ -34,6 +34,7 @@ 
  #include <asm/types.h>
  #include <uuid/uuid.h>
  #include "common/utils.h"
+#include "common/path-utils.h"
  #include "cmds/commands.h"
  #include "common/send-utils.h"
  #include "common/send-stream.h"
diff --git a/common/send-utils.h b/common/send-utils.h
index dd67b3fe..74cc6fc4 100644
--- a/common/send-utils.h
+++ b/common/send-utils.h
@@ -104,9 +104,6 @@  void subvol_uuid_search_add(struct subvol_uuid_search *s,
  
  int btrfs_subvolid_resolve(int fd, char *path, size_t path_len, u64 subvol_id);
  
-int path_cat_out(char *out, const char *p1, const char *p2);
-int path_cat3_out(char *out, const char *p1, const char *p2, const char *p3);
-
  #ifdef __cplusplus
  }
  #endif
diff --git a/mkfs/rootdir.c b/mkfs/rootdir.c
index 471d49da..f35544d6 100644
--- a/mkfs/rootdir.c
+++ b/mkfs/rootdir.c
@@ -33,6 +33,7 @@ 
  #include "common/messages.h"
  #include "kernel-shared/transaction.h"
  #include "common/utils.h"
+#include "common/path-utils.h"
  #include "mkfs/rootdir.h"
  #include "mkfs/common.h"
  #include "common/send-utils.h"