Skip to content

Commit

Permalink
Add newlines to logging calls that occur before retro_set_environment
Browse files Browse the repository at this point in the history
  • Loading branch information
JesseTG committed Aug 13, 2023
1 parent 10a48aa commit 06121b9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
6 changes: 3 additions & 3 deletions src/libretro/environment.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -395,9 +395,9 @@ PUBLIC_SYMBOL void retro_set_environment(retro_environment_t cb) {
retro::_supportsPowerStatus |= environment(RETRO_ENVIRONMENT_GET_DEVICE_POWER, nullptr);

if (retro::_supportsPowerStatus) {
retro::debug("Power state available");
retro::debug("Power state available\n");
} else {
retro::debug("Power state not available");
retro::debug("Power state not available\n");
}

environment(RETRO_ENVIRONMENT_GET_MESSAGE_INTERFACE_VERSION, &retro::_message_interface_version);
Expand Down Expand Up @@ -438,7 +438,7 @@ PUBLIC_SYMBOL void retro_set_environment(retro_environment_t cb) {

bool supports_no_game = true;
if (environment(RETRO_ENVIRONMENT_SET_SUPPORT_NO_GAME, &supports_no_game))
retro::log(RETRO_LOG_INFO, "Frontend supports no-game mode.");
retro::log(RETRO_LOG_INFO, "Frontend supports no-game mode.\n");

retro::microphone::init_interface();
}
Expand Down
7 changes: 3 additions & 4 deletions src/libretro/microphone.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ using std::nullopt;
namespace retro::microphone {
static optional<struct retro_microphone_interface> _microphone_interface;
static retro_microphone_t* _microphone_handle;

}

void retro::microphone::init_interface() noexcept {
Expand All @@ -43,13 +42,13 @@ void retro::microphone::init_interface() noexcept {
_microphone_interface = microphoneInterface;

if (microphoneInterface.interface_version == RETRO_MICROPHONE_INTERFACE_VERSION) {
retro::debug("Microphone support available (version %u)", microphoneInterface.interface_version);
retro::debug("Microphone support available (version %u)\n", microphoneInterface.interface_version);
} else {
retro::warn("Expected mic interface version %u, got %u.",
retro::warn("Expected mic interface version %u, got %u.\n",
RETRO_MICROPHONE_INTERFACE_VERSION, microphoneInterface.interface_version);
}
} else {
retro::warn("Microphone interface not available; substituting silence instead.");
retro::warn("Microphone interface not available; substituting silence instead.\n");
}
}
}
Expand Down

0 comments on commit 06121b9

Please sign in to comment.