RCSwitch-Webserver example not running on Mega 2560

HI,
i've tried to get the webserver example of RC switch to run, but it does not read any command and therefore always calls the httpResponseHome(client);
But why's that?

I'm on mega 2560 with ethernetshield.
i'm including the following:

#include <SPI.h>
#include <Ethernet.h>
#include <EthernetUdp.h>
#include <Time.h>
#include <TimeAlarms.h>
#include <RCSwitch.h>
#include "pitches.h"
char*  httpServer() {
  doMainSuff();
  EthernetClient client = server.available();
  if (client) {
    char sReturnCommand[32];
    int nCommandPos=-1;
    sReturnCommand[0] = '\0';
    while (client.connected()) {
      if (client.available()) {
        char c = client.read();
        if ((c == '\n') || (c == ' ' && nCommandPos>-1)) {
          sReturnCommand[nCommandPos] = '\0';
          if (strcmp(sReturnCommand, "\0") == 0) {
            Serial.print(sReturnCommand);
            Serial.println("httpResponeHome ");
            httpResponseHome(client);
          } else {
            Serial.print("processCommand ");
            Serial.println(sReturnCommand);
            processCommand(sReturnCommand);
            httpResponseRedirect(client);
          }
          break;
        }
        if (nCommandPos>-1) {
          sReturnCommand[nCommandPos++] = c;
        }
        if (c == '?' && nCommandPos == -1) {
          nCommandPos = 0;
        }
      }
      if (nCommandPos > 30) {
        Serial.print("414");
        httpResponse414(client);
        sReturnCommand[0] = '\0';
        break;
      }
    }
    if (nCommandPos!=-1) {
      sReturnCommand[nCommandPos] = '\0';
    }
    // give the web browser time to receive the data
    Alarm.delay(1);
    client.stop();
    
    return sReturnCommand;
  }
  return '\0';
}

once more thanks for advice

char*  httpServer() {
  doMainSuff();
  EthernetClient client = server.available();
  if (client) {
    char sReturnCommand[32];
// snip
    return sReturnCommand;
  }
  return '\0';
}

Returning a pointer to a variable that has gone out of scope is WRONG!

Some Serial.print() statements, to see what you actually get from the client might prove illuminating.

i've tried to get the webserver example of RC switch to run

But, I don't want to tell you where I got RCSwitch...

Have you tried taking your snippets to http://snippets-r-us.com?