Hello, Damien Zammit, le sam. 28 mars 2020 16:50:41 +1100, a ecrit: > I am sending this primarily because I don't want to lose these patches.
Ok, I already have comments on them :) + /* Parse @master:/dev/hello */ + master = strdup (name); + copy = strdup (name); + pos = strchr (copy, ':'); + *pos = '\0'; + sprintf(master, "%s", ©[1]); There is no need to make a copy, strdup the whole string and then use sprintf. Better do something like: pos = strchr(name, ':') master = strndup(name+1, pos-(name+1)); Samuel