Replace assert by cleaner exit(1)