Commit e5cb2927 authored by Junio C Hamano's avatar Junio C Hamano

Merge branch 'dl/flex-str-cocci' into next

Code clean-up.

* dl/flex-str-cocci:
  cocci: FLEX_ALLOC_MEM to FLEX_ALLOC_STR
  midx.c: convert FLEX_ALLOC_MEM to FLEX_ALLOC_STR
parents 39679dde 0cf2b0a0
@@
expression str;
identifier x, flexname;
@@
- FLEX_ALLOC_MEM(x, flexname, str, strlen(str));
+ FLEX_ALLOC_STR(x, flexname, str);
@@
expression str;
identifier x, ptrname;
@@
- FLEXPTR_ALLOC_MEM(x, ptrname, str, strlen(str));
+ FLEXPTR_ALLOC_STR(x, ptrname, str);
......@@ -71,7 +71,7 @@ struct multi_pack_index *load_multi_pack_index(const char *object_dir, int local
midx_map = xmmap(NULL, midx_size, PROT_READ, MAP_PRIVATE, fd, 0);
FLEX_ALLOC_MEM(m, object_dir, object_dir, strlen(object_dir));
FLEX_ALLOC_STR(m, object_dir, object_dir);
m->fd = fd;
m->data = midx_map;
m->data_len = midx_size;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment