strtok loses value and does not execute while more than once

I'm having problems using two strtok (), one within the while () of the other, the first variable receives the value returned from strtok () to traverse a while () and within the while () a second variable receives the value of strtok () of the first variable and when that second variable receives the value the while does not run the second time and if I comment the line with the second variable it runs.
In the example I am testing I have a char array that separates the parameters by '#' and then I get the params and break through the '=' to get the parameter name and value.

Why does the second variable make the first 'lost'?

My code:

void loop()
{
  char teste[ ] = "action=getData#time=121341234";
  
  char* pch;
  char* pch2;
  char* stringAux;
  int cont = 0;
  
  pch = strtok (teste,"#");
  
  while (pch != NULL)
  {
    if(strstr(pch, "=")) {

      Serial.print(F("IF: "));
      Serial.print(pch);
            
      cont = 0;
      pch2 = strtok (pch, "=");
      
    }
    pch = strtok (NULL, "#");
  }
    
  while(1);
}

strtok is NOT re-entrant, and it modifies the string each time you call it:

char teste[ ] = "action=getData#time=121341234";
char* pch;
char* pch2;

  pch = strtok (teste,"#");
  // pch parses teste, starting at teste[0]
  // teste now = "action=getData\0time=121341234"
  // pch now = &teste[0] = "action=getData";
  
  while (pch != NULL)
  {[color=#222222][/color]
      pch2 = strtok (pch, "=");
      // strtok parses pch, starting at pch[0], which is teste[0]
      // teste now = "action\0getData\0time=121341234"
      // pch2 now = &teste[0] = "action";
  }
  pch = strtok (NULL, "#");
  // strtok parse pch, starting at pch[7] = "getData"
  // teste now = "action\0getData\0time=121341234"
  // pch2 now = &teste[7] = "getData"

Regards,
Ray L.