strncpy(ev->attr.probe.symbol_name, name, LTTNG_SYMBOL_NAME_LEN);
ev->attr.probe.symbol_name[LTTNG_SYMBOL_NAME_LEN - 1] = '\0';
DBG("probe symbol %s", ev->attr.probe.symbol_name);
- if (strlen(s_hex) == 0) {
+ if (*s_hex == '\0') {
ERR("Invalid probe offset %s", s_hex);
ret = -1;
goto end;
/* Check for address */
ret = sscanf(opt, "%s", s_hex);
if (ret > 0) {
- if (strlen(s_hex) == 0) {
+ if (*s_hex == '\0') {
ERR("Invalid probe address %s", s_hex);
ret = -1;
goto end;
int i = 0;
char str[LTTNG_SYMBOL_NAME_LEN];
- while (inputstr[i] != '\0' && i < LTTNG_SYMBOL_NAME_LEN) {
+ while (i < LTTNG_SYMBOL_NAME_LEN && inputstr[i] != '\0') {
str[i] = toupper(inputstr[i]);
i++;
}