[PATCH 02/14] Refactor and add code for (lv) 'lv_path' get function.

Petr Rockai <[email protected]>
Newsgroups dev.linux.lists.lvm-devel
Message-ID <[email protected].>
Dave Wysochanski <[email protected]> writes:

>> Should the above dm_pool_zalloc/dm_snprintf go into some
>> dm_pool_asprintf, in fact? That would also remove that "len"
>> computation and make this function completely trivial. We already
>> have dm_asprintf (which uses dm_malloc). You could probably
>> parametrise dm_asprintf with the strdup function into
>> dm_generic_asprintf and have both dm_asprintf and dm_pool_asprintf
>> implemented in terms of that.

> If it's ok with you, I may defer these to a couple cleanup patches.
> They are good suggestions but I'm mostly focused on straight moving
> and refactoring for this patch set.

Sure, no problem. That can be done later. The patch is, logic-wise, in
order, as far as I can tell. The suggestions are quite optional, and of
course there's always a tradeoff. Ok to check in, I'll look at factoring
in dm_pool_asprintf later.

Yours,
   Petr.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.