String to char array for publish

Here I form a String and publish:

 powerInfo.concat( String(CalculatedVoltage,2) );
      xSemaphoreGive( sema_CalculatedVoltage );
      powerInfo.concat( ",");
      powerInfo.concat( String(mA,2) );
      powerInfo.concat( ",");
      powerInfo.concat( String(Power,4) );
      xSemaphoreTake( sema_MQTT_KeepAlive, portMAX_DELAY ); // whiles MQTTlient.loop() is running no other mqtt operations should be in process
      MQTTclient.publish( topicPower, powerInfo.c_str() );

Might give you a clue.