Hi,
I can see three possible problems:
1. MMU configuration - have you changed anything in MMU?
2. FLASH_BIUCR configuration - are you updating the number of wait states for flash (APC, WWSC, RWSC)?
3. Programming of non-erased flash - as you wrote, that's probably not the case.
Is it possible to read the flash after reset? Did you step the code? Is there any specific command/instruction that makes it unreadable? Once the flash becomes unreadable, is it possible to read the flash after next reset?
Regards,
Lukas