summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorchenzizhan <[email protected]>2023-11-03 17:14:46 +0800
committerchenzizhan <[email protected]>2023-11-03 17:18:06 +0800
commit42ec6d3f614bc840f6463f80ef4bd68239c90a80 (patch)
tree83d7e96de2b5d5c8d710621f11f9e920b6db225e
parent5d620841ecb273a80699ebbb0904d52be1f4e031 (diff)
a type
-rw-r--r--include/fieldstat/fieldstat.h2
-rw-r--r--src/fieldstat.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/include/fieldstat/fieldstat.h b/include/fieldstat/fieldstat.h
index 0e48098..6f44d6a 100644
--- a/include/fieldstat/fieldstat.h
+++ b/include/fieldstat/fieldstat.h
@@ -122,7 +122,7 @@ int fieldstat_register_hist(struct fieldstat *instance, const char *metric_name,
* In comprehensive mode, a full cube cannot be added any more cells.
* In topk mode, every increment matters, so even the cube is full, the cell can also replace the least frequent cell.
*/
-int fieldstat_counter_incrby(struct fieldstat *instance, int cube_id, int metric_id, const struct fieldstat_tag *tags, size_t n_tag, long increment);
+int fieldstat_counter_incrby(struct fieldstat *instance, int cube_id, int metric_id, const struct fieldstat_tag *tags, size_t n_tag, long long increment);
/*
* @brief let the value of counter metric equal to value. Other annotations refer to fieldstat_counter_incrby.
diff --git a/src/fieldstat.c b/src/fieldstat.c
index 89ac879..210103e 100644
--- a/src/fieldstat.c
+++ b/src/fieldstat.c
@@ -582,7 +582,7 @@ int check_before_add(const struct fieldstat *instance, int cube_id, int metric_i
return FS_OK;
}
-int fieldstat_counter_incrby(struct fieldstat *instance, int cube_id, int metric_id, const struct fieldstat_tag *tags, size_t n_tag, long increment)
+int fieldstat_counter_incrby(struct fieldstat *instance, int cube_id, int metric_id, const struct fieldstat_tag *tags, size_t n_tag, long long increment)
{
int ret = check_before_add(instance, cube_id, metric_id, METRIC_TYPE_COUNTER);
if (ret != FS_OK) {