Rhino stop working using my CustomObjectSelect

I make use of a "Custom"ObjectSelect inside my c#-Commands and Rhino is crashing if i select object bevor i running my command but not if i select the objects after starting the command.

Rhino is stop reponsing and fill up my memory really fast (1-2GB in 5 Seconds) and jump between 2 and 5GB until i kill it.

Here is an ExampleCommand with not really more than my ObjectSelectCode TestCommand.cs (2.4 KB)

Whats wrong?

Once you select an object, it stays selected. This means that your while loop will keep looping because of this

if (go.ObjectsWerePreselected)
    go.EnablePreSelect(true, false);
    continue; // with one pre-selected object, you keep hitting this over and over
break; // you never get here

Essentially, you are in an infinite loop that will crash at some point.