char *output;
char *ptr = strchr(output, ':');
   32
   33             // Copy the length of ptr - 1 to the target variable
   34             int size = ptr - output - 1;
this code is meant to find the length of the string before the colon