How do I compare the received data from a nRF24L01 module?

I can PRINT the received data, but I can't compare them with something else.

I use RF24 library.

On transmitter side I send the array of chars char text[] = "porta"; like this:

void porta_function() {
  char text[] = "porta";
  radio.write(&text, sizeof(text)); }

On receiver side I receive and print this array with no problem:

void loop() {
  while(radio.available()) {
    char text[32] = "";, sizeof(text));
    Serial.println(text); }

But when I add in the loop this: if(text == "led") { Serial.println("OK"); } the whole loop stops working although it compiles. I don't even get the print of Serial.println(text)

What is my mistake?

See strcmp and strncmp.