diff options
author | hunt <hunt> | 2005-11-09 08:24:52 +0000 |
---|---|---|
committer | hunt <hunt> | 2005-11-09 08:24:52 +0000 |
commit | 66f95fac49b0789dbf33026643c015c563b57572 (patch) | |
tree | 146e368636cf39e68a9ce6e127d2d8dc43a992e1 /runtime/map-values.c | |
parent | df27664107205cccec6eacb890d6800db7ee95cc (diff) | |
download | systemtap-steved-66f95fac49b0789dbf33026643c015c563b57572.tar.gz systemtap-steved-66f95fac49b0789dbf33026643c015c563b57572.tar.xz systemtap-steved-66f95fac49b0789dbf33026643c015c563b57572.zip |
2005-11-09 Martin Hunt <hunt@redhat.com>
* map.h (struct map_root): Delete fields
used by old API.
* map.c: Remove old map API functions.
* map-stat.c (_stp_map_add_stat): Delete.
(_stp_pmap_new_hstat_linear): Move here from map.c.
(_stp_pmap_new_hstat_log): Ditto.
* list.c: Deleted.
* map-keys.c: Deleted.
* map-values.c: Deleted.
* map-int.c: Deleted.
Diffstat (limited to 'runtime/map-values.c')
-rw-r--r-- | runtime/map-values.c | 58 |
1 files changed, 0 insertions, 58 deletions
diff --git a/runtime/map-values.c b/runtime/map-values.c deleted file mode 100644 index d41d85b1..00000000 --- a/runtime/map-values.c +++ /dev/null @@ -1,58 +0,0 @@ -/* -*- linux-c -*- - * Map value functions - * Copyright (C) 2005 Red Hat Inc. - * - * This file is part of systemtap, and is free software. You can - * redistribute it and/or modify it under the terms of the GNU General - * Public License (GPL); either version 2, or (at your option) any - * later version. - */ - -#ifndef _MAP_VALUES_C_ -#define _MAP_VALUES_C_ - -/** @file map-values.c - * @brief Includes the proper value functions for maps. - */ - -#include "map.h" -#include "map-str.c" -#include "map-stat.c" -#include "map-int.c" - -/** Adds an int64 to the current element's value. - * This adds an int64 to the current element's value. The map must have been created - * to hold int64s or stats. - * - * If the element doesn't exist, it is created. If no current element (key) - * is set for the map, this function does nothing. - * @param map - * @param val value - * @returns \li \c 0 on success \li \c -1 on overflow \li \c -2 on bad map or key - * @ingroup map_set - */ -int _stp_map_add_int64 (MAP map, int64_t val) -{ - if (map == NULL) - return -2; - - if (map->type == INT64) - return __stp_map_set_int64 (map, val, 1); - - if (map->type == STAT) - return _stp_map_add_stat (map, val); - - /* shouldn't get here */ - return -2; -} - -unsigned _stp_map_entry_exists (MAP map) -{ - if (map == NULL || map->create || map->key == NULL) - return 0; - return 1; -} - - -#endif /* _MAP_VALUES_C_ */ - |