Can you please post your complete project, so that we all can have a look at all of your settings. To do so, use
Creator->File->Create Workspace Bundle (minimal)
and attach the resulting file.
By any chance: did you configure the UART to a bigger larger than 4 bytes? Then the internal interrupt handling probably reads the data before you do, clearing that flag.
it works just fine now
it was a bad hardware connection on the bread board but the code is correct