[Asterisk-code-review] vector: Additional string vector definitions. (asterisk[master])

Corey Farrell asteriskteam at digium.com
Sun Jan 14 18:05:28 CST 2018


Corey Farrell has posted comments on this change. ( https://gerrit.asterisk.org/7871 )

Change subject: vector: Additional string vector definitions.
......................................................................


Patch Set 5:

(1 comment)

https://gerrit.asterisk.org/#/c/7871/5/main/strings.c
File main/strings.c:

https://gerrit.asterisk.org/#/c/7871/5/main/strings.c@411
PS5, Line 411: 	while ((cur = strsep(&buf, delim))) {
             : 		if (excludes_cmp && AST_VECTOR_GET_CMP(dest, cur, !excludes_cmp)) {
> The strip and empty string skip functionality would be:
So then should I replace excludes_cmp with an 'int flags' that would allow control of duplicate handling, trimming and skipping blanks?

enum ast_vector_string_split_flags {
  AST_VECTOR_STRING_SPLIT_EXCLUDE_BLANKS = 0x01,
  AST_VECTOR_STRING_SPLIT_EXCLUDE_DUPS = 0x02,
  AST_VECTOR_STRING_SPLIT_EXCLUDE_DUPS_I = 0x03,
  AST_VECTOR_STRING_SPLIT_TRIM = 0x08,
};



-- 
To view, visit https://gerrit.asterisk.org/7871
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I1bf02a1efeb2baeea11c59c557d39dd1197494d7
Gerrit-Change-Number: 7871
Gerrit-PatchSet: 5
Gerrit-Owner: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: George Joseph <gjoseph at digium.com>
Gerrit-Reviewer: Jenkins2
Gerrit-Reviewer: Kevin Harwell <kharwell at digium.com>
Gerrit-Reviewer: Richard Mudgett <rmudgett at digium.com>
Gerrit-Comment-Date: Mon, 15 Jan 2018 00:05:28 +0000
Gerrit-HasComments: Yes
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20180114/ac78165e/attachment-0001.html>


More information about the asterisk-code-review mailing list