summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
Diffstat (limited to 'source3')
-rw-r--r--source3/include/proto.h2
-rw-r--r--source3/lib/util_str.c41
2 files changed, 0 insertions, 43 deletions
diff --git a/source3/include/proto.h b/source3/include/proto.h
index 199ee4836c..2cb21f5ab6 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -1435,8 +1435,6 @@ size_t strlen_m_ext_term(const char *s, const charset_t src_charset,
size_t strlen_m(const char *s);
size_t strlen_m_term(const char *s);
size_t strlen_m_term_null(const char *s);
-char *binary_string_rfc2254(TALLOC_CTX *mem_ctx, const uint8_t *buf, int len);
-char *binary_string(char *buf, int len);
int fstr_sprintf(fstring s, const char *fmt, ...);
bool str_list_sub_basic( char **list, const char *smb_name,
const char *domain_name );
diff --git a/source3/lib/util_str.c b/source3/lib/util_str.c
index b26bde81c4..6a17297231 100644
--- a/source3/lib/util_str.c
+++ b/source3/lib/util_str.c
@@ -1576,47 +1576,6 @@ size_t strlen_m_term_null(const char *s)
return len+1;
}
-/**
- Return a RFC2254 binary string representation of a buffer.
- Used in LDAP filters.
- Caller must free.
-**/
-
-char *binary_string_rfc2254(TALLOC_CTX *mem_ctx, const uint8_t *buf, int len)
-{
- char *s;
- int i, j;
- const char *hex = "0123456789ABCDEF";
- s = talloc_array(mem_ctx, char, len * 3 + 1);
- if (s == NULL) {
- return NULL;
- }
- for (j=i=0;i<len;i++) {
- s[j] = '\\';
- s[j+1] = hex[((unsigned char)buf[i]) >> 4];
- s[j+2] = hex[((unsigned char)buf[i]) & 0xF];
- j += 3;
- }
- s[j] = 0;
- return s;
-}
-
-char *binary_string(char *buf, int len)
-{
- char *s;
- int i, j;
- const char *hex = "0123456789ABCDEF";
- s = (char *)SMB_MALLOC(len * 2 + 1);
- if (!s)
- return NULL;
- for (j=i=0;i<len;i++) {
- s[j] = hex[((unsigned char)buf[i]) >> 4];
- s[j+1] = hex[((unsigned char)buf[i]) & 0xF];
- j += 2;
- }
- s[j] = 0;
- return s;
-}
/**
Just a typesafety wrapper for snprintf into a fstring.