Getting strange chars in Serial output from time to time

I ran this code with random values and didn't get a single glitch. That tends to indicate that the problem is elsewhere in your code. Perhaps if you provided the rest of the code, someone might spot an error.

void setup()
{
  Serial.begin(115200);
  delay(200);
}

void loop()
{
  byte notifydata[18];

  for (int i = 0; i < 18; i++)
  {
    notifydata[i] = random(256);
  }

  char strkal[10] = "";
  sprintf(strkal, "0x%02X%02X%02X", notifydata[4], notifydata[5], notifydata[6]);
  unsigned long statkal = strtol(strkal, NULL, 0);

  char strdist[10] = "";
  sprintf(strdist, "0x%02X%02X", notifydata[7], notifydata[8]);
  unsigned long statdistance = strtol(strdist, NULL, 0);

  char strstep[10] = "";
  sprintf(strstep, "0x%02X%02X%02X", notifydata[9], notifydata[10], notifydata[11]);
  unsigned long statstep = strtol(strstep, NULL, 0);

  char strtime[10] = "";
  sprintf(strtime, "0x%02X%02X", notifydata[12], notifydata[13]);
  unsigned long stattime = strtol(strtime, NULL, 0);

  char buff[100] = "";
  sprintf(buff, "Data - Kcal: %lu  Time:%lu  Distance:%lu  Step: %lu", statkal, stattime, statdistance, statstep);
  Serial.println(buff);

  delay(500);
}