]> git.saurik.com Git - apt.git/blobdiff - apt-pkg/contrib/strutl.cc
Merge branch 'debian/sid' into debian/experimental
[apt.git] / apt-pkg / contrib / strutl.cc
index df02c3499c5b681041c27b9a3e9eef4c4fe6b535..d06637155b48e7ea8977f1e7cbc5006ed01351af 100644 (file)
@@ -1291,6 +1291,18 @@ bool CheckDomainList(const string &Host,const string &List)
    return false;
 }
                                                                        /*}}}*/
+// strv_length - Return the length of a NULL-terminated string array   /*{{{*/
+// ---------------------------------------------------------------------
+/* */
+size_t strv_length(const char **str_array)
+{
+   size_t i;
+   for (i=0; str_array[i] != NULL; i++)
+      /* nothing */
+      ;
+   return i;
+}
+
 // DeEscapeString - unescape (\0XX and \xXX) from a string             /*{{{*/
 // ---------------------------------------------------------------------
 /* */