Commit 58345f4e9c7bf2a91f6614267bf86639bacbe66d

Ran Benita 2013-12-02T14:14:41

atom: drop {xkb_,}atom_strdup Even though in 112cccb18ad1bc877b3c4a87fa536ea085c761b5 I said it might be useful, it's not. So remove it. Signed-off-by: Ran Benita <ran234@gmail.com>

diff --git a/src/atom.c b/src/atom.c
index a7033c4..dc6e794 100644
--- a/src/atom.c
+++ b/src/atom.c
@@ -134,12 +134,6 @@ atom_text(struct atom_table *table, xkb_atom_t atom)
     return darray_item(table->table, atom)->string;
 }
 
-char *
-atom_strdup(struct atom_table *table, xkb_atom_t atom)
-{
-    return strdup_safe(atom_text(table, atom));
-}
-
 static bool
 find_node_pointer(struct atom_table *table, const char *string, size_t len,
                   struct atom_node ***nodep_out, unsigned int *fingerprint_out)
diff --git a/src/atom.h b/src/atom.h
index 94c1494..1bf8e49 100644
--- a/src/atom.h
+++ b/src/atom.h
@@ -43,9 +43,6 @@ xkb_atom_t
 atom_intern(struct atom_table *table, const char *string, size_t len,
             bool steal);
 
-char *
-atom_strdup(struct atom_table *table, xkb_atom_t atom);
-
 const char *
 atom_text(struct atom_table *table, xkb_atom_t atom);
 
diff --git a/src/context.c b/src/context.c
index bf76ac2..6ecc4b3 100644
--- a/src/context.c
+++ b/src/context.c
@@ -345,12 +345,6 @@ xkb_atom_steal(struct xkb_context *ctx, char *string)
     return atom_intern(ctx->atom_table, string, strlen(string), true);
 }
 
-char *
-xkb_atom_strdup(struct xkb_context *ctx, xkb_atom_t atom)
-{
-    return atom_strdup(ctx->atom_table, atom);
-}
-
 const char *
 xkb_atom_text(struct xkb_context *ctx, xkb_atom_t atom)
 {
diff --git a/src/context.h b/src/context.h
index c9bb277..67e68d9 100644
--- a/src/context.h
+++ b/src/context.h
@@ -57,9 +57,6 @@ xkb_atom_intern(struct xkb_context *ctx, const char *string, size_t len);
 xkb_atom_t
 xkb_atom_steal(struct xkb_context *ctx, char *string);
 
-char *
-xkb_atom_strdup(struct xkb_context *ctx, xkb_atom_t atom);
-
 const char *
 xkb_atom_text(struct xkb_context *ctx, xkb_atom_t atom);