summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2012-02-09 12:49:45 +1100
committerAndrew Bartlett <abartlet@samba.org>2012-02-10 16:45:13 +1100
commitefc210d5208a2da1fc33c7ebd745bf806dd26f62 (patch)
treed12a8a670f350367cfa6be66e7f5d2d2db382c26 /lib
parentfc5a214d71ac46d031098afb3b8ccf2de472ef94 (diff)
downloadsamba-efc210d5208a2da1fc33c7ebd745bf806dd26f62.tar.gz
samba-efc210d5208a2da1fc33c7ebd745bf806dd26f62.tar.bz2
samba-efc210d5208a2da1fc33c7ebd745bf806dd26f62.zip
lib/util: Remove unused str_format_nbt_domain()
Found by callcatcher: http://www.skynet.ie/~caolan/Packages/callcatcher.html Andrew Bartlett
Diffstat (limited to 'lib')
-rw-r--r--lib/util/samba_util.h6
-rw-r--r--lib/util/util_str.c35
2 files changed, 0 insertions, 41 deletions
diff --git a/lib/util/samba_util.h b/lib/util/samba_util.h
index 5ce2e5e535..8e8e7c1abd 100644
--- a/lib/util/samba_util.h
+++ b/lib/util/samba_util.h
@@ -334,12 +334,6 @@ _PUBLIC_ char *rfc1738_escape_unescaped(TALLOC_CTX *mem_ctx, const char *url);
_PUBLIC_ char *rfc1738_escape_part(TALLOC_CTX *mem_ctx, const char *url);
/**
- format a string into length-prefixed dotted domain format, as used in NBT
- and in some ADS structures
-**/
-_PUBLIC_ const char *str_format_nbt_domain(TALLOC_CTX *mem_ctx, const char *s);
-
-/**
* Add a string to an array of strings.
*
* num should be a pointer to an integer that holds the current
diff --git a/lib/util/util_str.c b/lib/util/util_str.c
index 388d7887ef..9379304cfb 100644
--- a/lib/util/util_str.c
+++ b/lib/util/util_str.c
@@ -32,41 +32,6 @@
**/
/**
- format a string into length-prefixed dotted domain format, as used in NBT
- and in some ADS structures
-**/
-_PUBLIC_ const char *str_format_nbt_domain(TALLOC_CTX *mem_ctx, const char *s)
-{
- char *ret;
- int i;
- if (!s || !*s) {
- return talloc_strdup(mem_ctx, "");
- }
- ret = talloc_array(mem_ctx, char, strlen(s)+2);
- if (!ret) {
- return ret;
- }
-
- memcpy(ret+1, s, strlen(s)+1);
- ret[0] = '.';
-
- for (i=0;ret[i];i++) {
- if (ret[i] == '.') {
- char *p = strchr(ret+i+1, '.');
- if (p) {
- ret[i] = p-(ret+i+1);
- } else {
- ret[i] = strlen(ret+i+1);
- }
- }
- }
-
- talloc_set_name_const(ret, ret);
-
- return ret;
-}
-
-/**
* Parse a string containing a boolean value.
*
* val will be set to the read value.