kdb cmerge: Return values for set statistics
@@ -46,6 +46,7 @@ static int getStatisticalValue (Key * informationKey, char * metaName)
* @param informationKey contains the statistics in its meta information
* @param metaName which statistic to set
* @param value which value to set it to, must be a number
+ * @returns 0 on success, 1 otherwise.
*
* This enforces that a number is set.
*/
@@ -69,14 +70,15 @@ static void setStatisticalValue (Key * informationKey, char * metaName, int valu
"Statistical value %d was too large for its buffer. This happened with meta name %s.",
value, metaName);
}
- return;
+ return 1;
}
ssize_t size = keySetMeta (informationKey, metaName, stringy);
if (size <= 0)
{
ELEKTRA_SET_INTERNAL_ERROR (informationKey, "Could not set statistical value.");
- return;
+ return 1;
}
+ return 0;
}
/**
