summaryrefslogtreecommitdiffstats
path: root/runtime/map.c
diff options
context:
space:
mode:
authorhunt <hunt>2005-04-07 15:17:29 +0000
committerhunt <hunt>2005-04-07 15:17:29 +0000
commit3d4bc8bea6b45893bd4b49f44df26bd602b4cba5 (patch)
treebae3fb1bc5fcbd7906574b6902c649b203274a3f /runtime/map.c
parent6e01db401be4a19e6d81d9955d055e2f4e1b6aea (diff)
downloadsystemtap-steved-3d4bc8bea6b45893bd4b49f44df26bd602b4cba5.tar.gz
systemtap-steved-3d4bc8bea6b45893bd4b49f44df26bd602b4cba5.tar.xz
systemtap-steved-3d4bc8bea6b45893bd4b49f44df26bd602b4cba5.zip
Update to use relayfs.
Diffstat (limited to 'runtime/map.c')
-rw-r--r--runtime/map.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/runtime/map.c b/runtime/map.c
index 936383be..7e5caa49 100644
--- a/runtime/map.c
+++ b/runtime/map.c
@@ -8,6 +8,7 @@
#include "map.h"
#include "alloc.c"
+#include "string.c"
static int map_sizes[] = {
sizeof(struct map_node_int64),
@@ -641,6 +642,11 @@ void _stp_map_set_str(MAP map, char *val)
}
}
+void _stp_map_set_string (MAP map, String str)
+{
+ _stp_map_set_str (map, str->buf);
+}
+
/** Gets the current element's value.
* @param map
* @returns A string pointer. If the current element is not set or doesn't exist, returns NULL.
@@ -841,7 +847,7 @@ void _stp_list_clear(MAP map)
}
if (map->num != 0) {
- dlog ("ERROR: list is supposed to be empty (has %d)\n", map->num);
+ _stp_log ("ERROR: list is supposed to be empty (has %d)\n", map->num);
}
}
@@ -856,6 +862,12 @@ inline void _stp_list_add_str(MAP map, char *str)
_stp_map_set_str(map, str);
}
+inline void _stp_list_add_string (MAP map, String str)
+{
+ _stp_map_key_long(map, map->num);
+ _stp_map_set_str(map, str->buf);
+}
+
/** Adds an int64 to a list.
* @param map
* @param val