0002-zck-declare-write_data-as-static.patch 1.2 KB

12345678910111213141516171819202122232425262728293031323334
  1. From 477c4e891bd4d9e41fcbaa07cd1a37c0975df5cc Mon Sep 17 00:00:00 2001
  2. From: James Hilliard <james.hilliard1@gmail.com>
  3. Date: Wed, 4 May 2022 16:32:48 -0600
  4. Subject: [PATCH] zck: declare write_data as static
  5. This needs to be declared static to avoid a symbol conflict:
  6. io.c:(.text+0xe8): multiple definition of `write_data'; src/zck.p/zck.c.o:zck.c:(.text+0x1f4): first defined here
  7. Fixes:
  8. - http://autobuild.buildroot.net/results/225/22590a7038a40da3700d56c1f82f7dc74225702a
  9. Signed-off-by: James Hilliard <james.hilliard1@gmail.com>
  10. [james.hilliard1@gmail.com: backport from upstream commit
  11. 477c4e891bd4d9e41fcbaa07cd1a37c0975df5cc]
  12. ---
  13. src/zck.c | 2 +-
  14. 1 file changed, 1 insertion(+), 1 deletion(-)
  15. diff --git a/src/zck.c b/src/zck.c
  16. index 7727479..83b2630 100644
  17. --- a/src/zck.c
  18. +++ b/src/zck.c
  19. @@ -159,7 +159,7 @@ static error_t parse_opt (int key, char *arg, struct argp_state *state) {
  20. static struct argp argp = {options, parse_opt, args_doc, doc};
  21. -void write_data(zckCtx *zck, char *data, ssize_t in_size) {
  22. +static void write_data(zckCtx *zck, char *data, ssize_t in_size) {
  23. if(zck_write(zck, data, in_size) < 0) {
  24. LOG_ERROR("%s", zck_get_error(zck));
  25. exit(1);
  26. --
  27. 2.25.1