diff --git a/360/main.c b/360/main.c index 14acd6c66b..c5c9544a94 100644 --- a/360/main.c +++ b/360/main.c @@ -162,7 +162,7 @@ static void init_settings (void) { if(!file_exists(SYS_CONFIG_FILE)) { - SSNES_ERR("Config file \"%s\" desn't exist! Creating...\n", "game:\\ssnes.cfg"); + SSNES_ERR("Config file \"%s\" desn't exist. Creating...\n", "game:\\ssnes.cfg"); FILE * f; f = fopen(SYS_CONFIG_FILE, "w"); fclose(f); @@ -212,7 +212,7 @@ static void save_settings (void) config_set_int(conf, "audio_mute", g_extern.audio_data.mute); if (!config_file_write(conf, SYS_CONFIG_FILE)) - SSNES_ERR("Failed to write config file to \"%s\"! Check permissions!\n", SYS_CONFIG_FILE); + SSNES_ERR("Failed to write config file to \"%s\". Check permissions.\n", SYS_CONFIG_FILE); free(conf); } diff --git a/audio/dsound.c b/audio/dsound.c index 3a31acb2f8..ce7b03d219 100644 --- a/audio/dsound.c +++ b/audio/dsound.c @@ -311,7 +311,7 @@ static void *dsound_init(const char *device, unsigned rate, unsigned latency) return ds; error: - SSNES_ERR("[DirectSound] Error occured in init!\n"); + SSNES_ERR("[DirectSound] Error occured in init.\n"); dsound_free(ds); return NULL; } diff --git a/audio/ext/ssnes_iir_filter.c b/audio/ext/ssnes_iir_filter.c index 171730be66..4c6b3f8685 100644 --- a/audio/ext/ssnes_iir_filter.c +++ b/audio/ext/ssnes_iir_filter.c @@ -8,7 +8,7 @@ // Simple IIR/EQ filter implementation, optimized for SSE3. -#ifdef __SSE3__ // Build with -march=native or -msse3 to let this be detected! D: +#ifdef __SSE3__ // Build with -march=native or -msse3 to let this be detected. D: #define USE_SSE3 #endif diff --git a/autosave.c b/autosave.c index 02940a4696..5537121108 100644 --- a/autosave.c +++ b/autosave.c @@ -73,7 +73,7 @@ static void autosave_thread(void *data) failed |= fflush(file) != 0; failed |= fclose(file) != 0; if (failed) - SSNES_WARN("Failed to autosave SRAM! Disk might be full.\n"); + SSNES_WARN("Failed to autosave SRAM. Disk might be full.\n"); } } diff --git a/cheats.c b/cheats.c index 95c0d5bcdb..e961f4b79e 100644 --- a/cheats.c +++ b/cheats.c @@ -201,7 +201,7 @@ static void cheat_manager_save_config(cheat_manager_t *handle, const char *path, if (!conf) { - SSNES_ERR("Cannot save XML cheat settings!\n"); + SSNES_ERR("Cannot save XML cheat settings.\n"); return; } @@ -223,7 +223,7 @@ static void cheat_manager_save_config(cheat_manager_t *handle, const char *path, config_set_string(conf, sha256, conf_str); if (!config_file_write(conf, path)) - SSNES_ERR("Failed to write XML cheat settings to \"%s\"! Check permissions!\n", path); + SSNES_ERR("Failed to write XML cheat settings to \"%s\". Check permissions.\n", path); config_file_free(conf); diff --git a/conf/config_file.c b/conf/config_file.c index a4c550b9a2..478f706fb5 100644 --- a/conf/config_file.c +++ b/conf/config_file.c @@ -254,7 +254,7 @@ static void add_sub_conf(config_file_t *conf, char *line) return; } - // Pilfer internal list! :D + // Pilfer internal list. :D add_child_list(conf, sub_conf); config_file_free(sub_conf); free(path); @@ -278,7 +278,7 @@ static bool parse_line(config_file_t *conf, struct entry_list *list, char *line) } } else if (conf->include_depth >= MAX_INCLUDE_DEPTH) - fprintf(stderr, "!!! #include depth exceeded for config! Might be a cycle.\n"); + fprintf(stderr, "!!! #include depth exceeded for config. Might be a cycle.\n"); // Skips to first character. while (isspace(*line)) diff --git a/driver.c b/driver.c index 02b656e570..ad773ca2ae 100644 --- a/driver.c +++ b/driver.c @@ -221,7 +221,7 @@ static void init_dsp_plugin(void) if (g_extern.audio_data.dsp_plugin->api_version != SSNES_DSP_API_VERSION) { - SSNES_ERR("DSP plugin API mismatch! SSNES: %d, Plugin: %d\n", SSNES_DSP_API_VERSION, g_extern.audio_data.dsp_plugin->api_version); + SSNES_ERR("DSP plugin API mismatch. SSNES: %d, Plugin: %d\n", SSNES_DSP_API_VERSION, g_extern.audio_data.dsp_plugin->api_version); goto error; } diff --git a/dynamic.c b/dynamic.c index 8b29930857..e5331d3936 100644 --- a/dynamic.c +++ b/dynamic.c @@ -199,9 +199,9 @@ void init_libsnes_sym(void) function_t sym = dylib_proc(NULL, "snes_init"); if (sym) { - SSNES_ERR("Serious problem! SSNES wants to load libsnes dyamically, but it is already linked!\n"); + SSNES_ERR("Serious problem. SSNES wants to load libsnes dyamically, but it is already linked.\n"); SSNES_ERR("This could happen if other modules SSNES depends on link against libsnes directly.\n"); - SSNES_ERR("Proceeding could cause a crash! Aborting ...\n"); + SSNES_ERR("Proceeding could cause a crash. Aborting ...\n"); ssnes_fail(1, "init_libsnes_sym()"); } @@ -380,7 +380,7 @@ static bool environment_cb(unsigned cmd, void *data) } default: - SSNES_LOG("Environ UNSUPPORTED (#%u)!\n", cmd); + SSNES_LOG("Environ UNSUPPORTED (#%u).\n", cmd); return false; } diff --git a/file.c b/file.c index 7be019f863..d9181f45d9 100644 --- a/file.c +++ b/file.c @@ -69,7 +69,7 @@ ssize_t read_file(const char *path, void **buf) rom_buf = malloc(len + 1); if (!rom_buf) { - SSNES_ERR("Couldn't allocate memory!\n"); + SSNES_ERR("Couldn't allocate memory.\n"); goto error; } @@ -197,7 +197,7 @@ static void patch_rom(uint8_t **buf, ssize_t *size) ups_error_t err = ups_apply_patch((const uint8_t*)patch_data, patch_size, ret_buf, ret_size, patched_rom, &target_size); if (err == UPS_SUCCESS) { - SSNES_LOG("ROM patched successfully (UPS)!\n"); + SSNES_LOG("ROM patched successfully (UPS).\n"); success = true; } else @@ -211,7 +211,7 @@ static void patch_rom(uint8_t **buf, ssize_t *size) bps_error_t err = bps_apply_patch((const uint8_t*)patch_data, patch_size, ret_buf, ret_size, patched_rom, &target_size); if (err == BPS_SUCCESS) { - SSNES_LOG("ROM patched successfully (BPS)!\n"); + SSNES_LOG("ROM patched successfully (BPS).\n"); success = true; } else @@ -261,7 +261,7 @@ static ssize_t read_rom_file(FILE* file, void** buf) uint8_t *rom_buf = (uint8_t*)malloc(buf_size); if (rom_buf == NULL) { - SSNES_ERR("Couldn't allocate memory!\n"); + SSNES_ERR("Couldn't allocate memory.\n"); return -1; } @@ -277,7 +277,7 @@ static ssize_t read_rom_file(FILE* file, void** buf) rom_buf = (uint8_t*)realloc(rom_buf, buf_size * 2); if (rom_buf == NULL) { - SSNES_ERR("Couldn't allocate memory!\n"); + SSNES_ERR("Couldn't allocate memory.\n"); return -1; } @@ -296,7 +296,7 @@ static ssize_t read_rom_file(FILE* file, void** buf) void *rom_buf = malloc(ret); if (rom_buf == NULL) { - SSNES_ERR("Couldn't allocate memory!\n"); + SSNES_ERR("Couldn't allocate memory.\n"); return -1; } @@ -395,7 +395,7 @@ static void dump_to_file_desperate(const void *data, size_t size, int type) strlcat(path, ramtype2str(type), sizeof(path)); if (dump_to_file(path, data, size)) - SSNES_WARN("Succeeded in saving RAM data to \"%s\". Phew! :D\n", path); + SSNES_WARN("Succeeded in saving RAM data to \"%s\". Phew ... :D\n", path); else goto error; @@ -452,7 +452,7 @@ bool load_state(const char *path) if (g_settings.block_sram_overwrite) { - SSNES_LOG("Blocking SRAM overwrite!\n"); + SSNES_LOG("Blocking SRAM overwrite.\n"); switch (g_extern.game_type) { case SSNES_CART_NORMAL: @@ -543,7 +543,7 @@ void save_ram_file(const char *path, int type) { if (!dump_to_file(path, data, size)) { - SSNES_ERR("Failed to save SNES RAM!\n"); + SSNES_ERR("Failed to save SNES RAM.\n"); SSNES_WARN("Attempting to recover ...\n"); dump_to_file_desperate(data, size, type); } @@ -774,7 +774,7 @@ static bool load_normal_rom(void) if (!psnes_load_cartridge_normal(xml_buf, (const uint8_t*)rom_buf, rom_len)) { - SSNES_ERR("ROM file is not valid!\n"); + SSNES_ERR("ROM file is not valid.\n"); free(rom_buf); free(xml_buf); return false; @@ -815,7 +815,7 @@ bool init_rom_file(enum ssnes_game_type type) break; default: - SSNES_ERR("Invalid ROM type!\n"); + SSNES_ERR("Invalid ROM type.\n"); return false; } diff --git a/general.h b/general.h index 9318726839..a08b228f99 100644 --- a/general.h +++ b/general.h @@ -489,7 +489,7 @@ static inline void ssnes_sleep(unsigned msec) } #define ssnes_assert(cond) \ - if (!(cond)) { SSNES_ERR("Assertion failed at %s:%d!\n", __FILE__, __LINE__); exit(2); } + if (!(cond)) { SSNES_ERR("Assertion failed at %s:%d.\n", __FILE__, __LINE__); exit(2); } static inline void ssnes_fail(int error_code, const char *error) { diff --git a/gfx/ext_gfx.c b/gfx/ext_gfx.c index 7dc16f225c..debb643991 100644 --- a/gfx/ext_gfx.c +++ b/gfx/ext_gfx.c @@ -215,7 +215,7 @@ static bool setup_video(ext_t *ext, const video_info_t *video, const input_drive if (SSNES_GRAPHICS_API_VERSION != ext->driver->api_version) { - SSNES_ERR("API version mismatch detected!\n"); + SSNES_ERR("API version mismatch detected.\n"); SSNES_ERR("Required API version: %d, Library version: %d\n", SSNES_GRAPHICS_API_VERSION, ext->driver->api_version); return false; } @@ -300,7 +300,7 @@ static void *video_ext_init(const video_info_t *video, const input_driver_t **in if (!(*g_settings.video.external_driver)) { - SSNES_ERR("External driver needs video_external_driver path to be set!\n"); + SSNES_ERR("External driver needs video_external_driver path to be set.\n"); goto error; } diff --git a/gfx/gl.c b/gfx/gl.c index a25a05ce1c..16b5cb5fe7 100644 --- a/gfx/gl.c +++ b/gfx/gl.c @@ -943,7 +943,7 @@ static void gl_check_fbo_dimensions(gl_t *gl) GLenum status = pglCheckFramebufferStatus(GL_FRAMEBUFFER); if (status != GL_FRAMEBUFFER_COMPLETE) - SSNES_WARN("Failed to reinit FBO texture!\n"); + SSNES_WARN("Failed to reinit FBO texture.\n"); SSNES_LOG("Recreating FBO texture #%d: %ux%u\n", i, gl->fbo_rect[i].width, gl->fbo_rect[i].height); } diff --git a/gfx/py_state/py_state.c b/gfx/py_state/py_state.c index 222c2b7fb8..aa845a0ef4 100644 --- a/gfx/py_state/py_state.c +++ b/gfx/py_state/py_state.c @@ -249,7 +249,7 @@ py_state_t *py_state_new(const char *script, unsigned is_file, const char *pycla SSNES_LOG("Initializing Python runtime ...\n"); PyImport_AppendInittab("snes", &PyInit_SNES); Py_Initialize(); - SSNES_LOG("Initialized Python runtime!\n"); + SSNES_LOG("Initialized Python runtime.\n"); py_state_t *handle = (py_state_t*)calloc(1, sizeof(*handle)); PyObject *hook = NULL; @@ -341,7 +341,7 @@ float py_state_get(py_state_t *handle, const char *id, if (!ret) { if (!handle->warned_ret) - SSNES_WARN("Didn't get return value from script! Bug?\n"); + SSNES_WARN("Didn't get return value from script. Bug?\n"); handle->warned_ret = true; return 0.0f; } diff --git a/gfx/sdlwrap.c b/gfx/sdlwrap.c index ad69fdf686..d5c202b41d 100644 --- a/gfx/sdlwrap.c +++ b/gfx/sdlwrap.c @@ -26,7 +26,7 @@ // SDL 1.2 is portable, sure, but you still need some platform specific workarounds ;) // Hopefully SDL 1.3 will solve this more cleanly :D -// Welcome to #ifdef HELL! :D +// Welcome to #ifdef HELL. :D // #if SDL_MODERN @@ -73,7 +73,7 @@ void sdlwrap_set_swap_interval(unsigned interval, bool inited) } #endif if (!success) - SSNES_WARN("Failed to set swap interval!\n"); + SSNES_WARN("Failed to set swap interval.\n"); } bool sdlwrap_init(void) @@ -87,7 +87,7 @@ bool sdlwrap_init(void) bool ret = SDL_Init(SDL_INIT_VIDEO) == 0; #endif if (!ret) - SSNES_ERR("Failed to init SDL video!\n"); + SSNES_ERR("Failed to init SDL video.\n"); return ret; } @@ -147,7 +147,7 @@ bool sdlwrap_set_video_mode( width, height, SDL_WINDOW_OPENGL | SDL_WINDOW_SHOWN | (fullscreen ? SDL_WINDOW_FULLSCREEN : resizable)); if (!g_window) { - SSNES_ERR("Failed to create SDL window!\n"); + SSNES_ERR("Failed to create SDL window.\n"); return false; } @@ -156,7 +156,7 @@ bool sdlwrap_set_video_mode( if (!SDL_SetVideoMode(width, height, bits, SDL_OPENGL | (fullscreen ? SDL_FULLSCREEN : resizable))) { - SSNES_ERR("Failed to create SDL window!\n"); + SSNES_ERR("Failed to create SDL window.\n"); return false; } #endif @@ -168,7 +168,7 @@ bool sdlwrap_set_video_mode( SDL_GL_GetAttribute(SDL_GL_SWAP_CONTROL, &attr); if (attr <= 0 && g_interval) { - SSNES_WARN("SDL failed to setup VSync, attempting to recover using native calls!\n"); + SSNES_WARN("SDL failed to setup VSync, attempting to recover using native calls.\n"); sdlwrap_set_swap_interval(g_interval, true); } #endif @@ -178,7 +178,7 @@ bool sdlwrap_set_video_mode( attr = 0; SDL_GL_GetAttribute(SDL_GL_DOUBLEBUFFER, &attr); if (attr <= 0) - SSNES_WARN("GL double buffer has not been enabled!\n"); + SSNES_WARN("GL double buffer has not been enabled.\n"); return true; } diff --git a/gfx/shader_cg.c b/gfx/shader_cg.c index c7fe04cc41..b6bcf9e852 100644 --- a/gfx/shader_cg.c +++ b/gfx/shader_cg.c @@ -886,7 +886,7 @@ static bool load_preset(const char *path) if (shaders < 1) { - SSNES_ERR("Need to define at least 1 shader!\n"); + SSNES_ERR("Need to define at least 1 shader.\n"); ret = false; goto end; } diff --git a/gfx/shader_glsl.c b/gfx/shader_glsl.c index 55e826bae9..c6c1714de8 100644 --- a/gfx/shader_glsl.c +++ b/gfx/shader_glsl.c @@ -327,7 +327,7 @@ static bool get_texture_image(const char *shader_path, xmlNodePtr ptr) { if (gl_teximage_cnt >= MAX_TEXTURES) { - SSNES_WARN("Too many texture images! Ignoring ...\n"); + SSNES_WARN("Too many texture images. Ignoring ...\n"); return true; } @@ -427,7 +427,7 @@ static bool get_script(const char *path, xmlNodePtr ptr) xmlChar *language = xmlGetProp(ptr, (const xmlChar*)"language"); if (!language || strcmp((const char*)language, "python") != 0) { - SSNES_ERR("Script language is not Python!\n"); + SSNES_ERR("Script language is not Python.\n"); if (language) xmlFree(language); return false; @@ -452,7 +452,7 @@ static bool get_script(const char *path, xmlNodePtr ptr) xmlChar *script = xmlNodeGetContent(ptr); if (!script) { - SSNES_ERR("No content in script!\n"); + SSNES_ERR("No content in script.\n"); return false; } gl_script_program = script; @@ -488,7 +488,7 @@ static bool get_import_value(xmlNodePtr ptr) if (!semantic || !id) { - SSNES_ERR("No semantic or ID for import value!\n"); + SSNES_ERR("No semantic or ID for import value.\n"); goto error; } @@ -530,7 +530,7 @@ static bool get_import_value(xmlNodePtr ptr) break; default: - SSNES_ERR("Invalid input slot for import!\n"); + SSNES_ERR("Invalid input slot for import.\n"); goto error; } } @@ -976,7 +976,7 @@ bool gl_glsl_init(const char *path) } //if (!gl_check_error()) - // SSNES_WARN("Detected GL error!\n"); + // SSNES_WARN("Detected GL error.\n"); if (gl_tracker_info_cnt > 0) { @@ -1003,7 +1003,7 @@ bool gl_glsl_init(const char *path) gl_snes_tracker = snes_tracker_init(&info); if (!gl_snes_tracker) - SSNES_WARN("Failed to init SNES tracker!\n"); + SSNES_WARN("Failed to init SNES tracker.\n"); } glsl_enable = true; diff --git a/gfx/xvideo.c b/gfx/xvideo.c index 53f54ed114..0d3bdcfda9 100644 --- a/gfx/xvideo.c +++ b/gfx/xvideo.c @@ -664,7 +664,7 @@ static void xv_render_msg(xv_t *xv, const char *msg, unsigned width, unsigned he unsigned alpha[2]; alpha[0] = a[(x >> 1) + 0]; - if (((x >> 1) + 1) == head->width) // We reached the end, uhoh! Branching like a BOSS! :D + if (((x >> 1) + 1) == head->width) // We reached the end, uhoh. Branching like a BOSS. :D alpha[1] = 0; else alpha[1] = a[(x >> 1) + 1]; diff --git a/movie.c b/movie.c index e44e4fb61a..b13735ba9d 100644 --- a/movie.c +++ b/movie.c @@ -144,20 +144,20 @@ static bool init_playback(bsv_movie_t *handle, const char *path) uint32_t header[4] = {0}; if (fread(header, sizeof(uint32_t), 4, handle->file) != 4) { - SSNES_ERR("Couldn't read movie header!\n"); + SSNES_ERR("Couldn't read movie header.\n"); return false; } // Compatibility with old implementation that used incorrect documentation. if (swap_if_little32(header[MAGIC_INDEX]) != BSV_MAGIC && swap_if_big32(header[MAGIC_INDEX]) != BSV_MAGIC) { - SSNES_ERR("Movie file is not a valid BSV1 file!\n"); + SSNES_ERR("Movie file is not a valid BSV1 file.\n"); return false; } if (swap_if_big32(header[CRC_INDEX]) != g_extern.cart_crc) { - SSNES_ERR("Cart CRC32s differ! Cannot play back!\n"); + SSNES_ERR("Cart CRC32s differ. Cannot play back.\n"); return false; } @@ -360,7 +360,7 @@ bool bsv_parse_header(const uint32_t *header, uint32_t magic) uint32_t in_bsv = swap_if_little32(header[MAGIC_INDEX]); if (in_bsv != BSV_MAGIC) { - SSNES_ERR("BSV magic mismatch, got 0x%x, expected 0x%x!\n", + SSNES_ERR("BSV magic mismatch, got 0x%x, expected 0x%x.\n", in_bsv, BSV_MAGIC); return false; } @@ -368,21 +368,21 @@ bool bsv_parse_header(const uint32_t *header, uint32_t magic) uint32_t in_magic = swap_if_big32(header[SERIALIZER_INDEX]); if (in_magic != magic) { - SSNES_ERR("Magic mismatch, got 0x%x, expected 0x%x!\n", in_magic, magic); + SSNES_ERR("Magic mismatch, got 0x%x, expected 0x%x.\n", in_magic, magic); return false; } uint32_t in_crc = swap_if_big32(header[CRC_INDEX]); if (in_crc != g_extern.cart_crc) { - SSNES_ERR("CRC32 mismatch, got 0x%x, expected 0x%x!\n", in_crc, g_extern.cart_crc); + SSNES_ERR("CRC32 mismatch, got 0x%x, expected 0x%x.\n", in_crc, g_extern.cart_crc); return false; } uint32_t in_state_size = swap_if_big32(header[STATE_SIZE_INDEX]); if (in_state_size != psnes_serialize_size()) { - SSNES_ERR("Serialization size mismatch, got 0x%x, expected 0x%x!\n", + SSNES_ERR("Serialization size mismatch, got 0x%x, expected 0x%x.\n", in_state_size, psnes_serialize_size()); return false; } diff --git a/netplay.c b/netplay.c index 5f598cef8f..cdc1fd7c59 100644 --- a/netplay.c +++ b/netplay.c @@ -563,19 +563,19 @@ static bool get_info(netplay_t *handle) if (g_extern.cart_crc != ntohl(header[0])) { - SSNES_ERR("Cart CRC32s differ! Cannot use different games!\n"); + SSNES_ERR("Cart CRC32s differ. Cannot use different games.\n"); return false; } if (implementation_magic_value() != ntohl(header[1])) { - SSNES_ERR("Implementations differ, make sure you're using exact same libsnes implementations and SSNES version!\n"); + SSNES_ERR("Implementations differ, make sure you're using exact same libsnes implementations and SSNES version.\n"); return false; } if (psnes_get_memory_size(SNES_MEMORY_CARTRIDGE_RAM) != ntohl(header[2])) { - SSNES_ERR("Cartridge SRAM sizes do not correspond!\n"); + SSNES_ERR("Cartridge SRAM sizes do not correspond.\n"); return false; } @@ -611,13 +611,13 @@ static bool get_info_spectate(netplay_t *handle) { if (!send_nickname(handle, handle->fd)) { - SSNES_ERR("Failed to send nickname to host!\n"); + SSNES_ERR("Failed to send nickname to host.\n"); return false; } if (!get_nickname(handle, handle->fd)) { - SSNES_ERR("Failed to receive nickname from host!\n"); + SSNES_ERR("Failed to receive nickname from host.\n"); return false; } @@ -630,14 +630,14 @@ static bool get_info_spectate(netplay_t *handle) if (!recv_all(handle->fd, header, sizeof(header))) { - SSNES_ERR("Cannot get header from host!\n"); + SSNES_ERR("Cannot get header from host.\n"); return false; } unsigned save_state_size = psnes_serialize_size(); if (!bsv_parse_header(header, implementation_magic_value())) { - SSNES_ERR("Received invalid BSV header from host!\n"); + SSNES_ERR("Received invalid BSV header from host.\n"); return false; } @@ -650,7 +650,7 @@ static bool get_info_spectate(netplay_t *handle) if (!recv_all(handle->fd, tmp_buf, size)) { - SSNES_ERR("Failed to receive save state from host!\n"); + SSNES_ERR("Failed to receive save state from host.\n"); free(tmp_buf); return false; } @@ -1020,14 +1020,14 @@ static bool netplay_get_cmd(netplay_t *handle) { if (cmd_size != sizeof(uint32_t)) { - SSNES_ERR("CMD_FLIP_PLAYERS has unexpected command size!\n"); + SSNES_ERR("CMD_FLIP_PLAYERS has unexpected command size.\n"); return netplay_cmd_nak(handle); } uint32_t flip_frame; if (!recv_all(handle->fd, &flip_frame, sizeof(flip_frame))) { - SSNES_ERR("Failed to receive CMD_FLIP_PLAYERS argument!\n"); + SSNES_ERR("Failed to receive CMD_FLIP_PLAYERS argument.\n"); return netplay_cmd_nak(handle); } @@ -1041,14 +1041,14 @@ static bool netplay_get_cmd(netplay_t *handle) handle->flip ^= true; handle->flip_frame = flip_frame; - SSNES_LOG("Netplay players are flipped!\n"); + SSNES_LOG("Netplay players are flipped.\n"); msg_queue_push(g_extern.msg_queue, "Netplay players are flipped.", 1, 180); return netplay_cmd_ack(handle); } default: - SSNES_ERR("Unknown netplay command received!\n"); + SSNES_ERR("Unknown netplay command received.\n"); return netplay_cmd_nak(handle); } } @@ -1074,14 +1074,14 @@ void netplay_flip_players(netplay_t *handle) // Make sure both clients are definitely synced up. if (handle->frame_count < (handle->flip_frame + 2 * UDP_FRAME_PACKETS)) { - msg = "Cannot flip players yet! Wait a second or two before attempting flip."; + msg = "Cannot flip players yet. Wait a second or two before attempting flip."; goto error; } if (netplay_send_cmd(handle, NETPLAY_CMD_FLIP_PLAYERS, &flip_frame_net, sizeof(flip_frame_net)) && netplay_get_response(handle)) { - SSNES_LOG("Netplay players are flipped!\n"); + SSNES_LOG("Netplay players are flipped.\n"); msg_queue_push(g_extern.msg_queue, "Netplay players are flipped.", 1, 180); // Queue up a flip well enough in the future. @@ -1212,7 +1212,7 @@ static int16_t netplay_get_spectate_input(netplay_t *handle, bool port, unsigned return swap_if_big16(inp); else { - SSNES_ERR("Connection with host was cut!\n"); + SSNES_ERR("Connection with host was cut.\n"); msg_queue_clear(g_extern.msg_queue); msg_queue_push(g_extern.msg_queue, "Connection with host was cut.", 1, 180); @@ -1247,7 +1247,7 @@ static void netplay_pre_frame_spectate(netplay_t *handle) int new_fd = accept(handle->fd, (struct sockaddr*)&their_addr, &addr_size); if (new_fd < 0) { - SSNES_ERR("Failed to accept incoming spectator!\n"); + SSNES_ERR("Failed to accept incoming spectator.\n"); return; } @@ -1270,14 +1270,14 @@ static void netplay_pre_frame_spectate(netplay_t *handle) if (!get_nickname(handle, new_fd)) { - SSNES_ERR("Failed to get nickname from client!\n"); + SSNES_ERR("Failed to get nickname from client.\n"); close(new_fd); return; } if (!send_nickname(handle, new_fd)) { - SSNES_ERR("Failed to send nickname to client!\n"); + SSNES_ERR("Failed to send nickname to client.\n"); close(new_fd); return; } @@ -1286,7 +1286,7 @@ static void netplay_pre_frame_spectate(netplay_t *handle) uint32_t *header = bsv_header_generate(&header_size, implementation_magic_value()); if (!header) { - SSNES_ERR("Failed to generate BSV header!\n"); + SSNES_ERR("Failed to generate BSV header.\n"); close(new_fd); return; } @@ -1296,7 +1296,7 @@ static void netplay_pre_frame_spectate(netplay_t *handle) if (!send_all(new_fd, header, header_size)) { - SSNES_ERR("Failed to send header to client!\n"); + SSNES_ERR("Failed to send header to client.\n"); close(new_fd); free(header); return; diff --git a/netplay_compat.h b/netplay_compat.h index a871001b5d..f920b51322 100644 --- a/netplay_compat.h +++ b/netplay_compat.h @@ -27,7 +27,7 @@ #endif #if defined(_WIN32) -// Woohoo, Winsock has headers from the STONE AGE! :D +// Woohoo, Winsock has headers from the STONE AGE. :D #define close(x) closesocket(x) #define CONST_CAST (const char*) #define NONCONST_CAST (char*) diff --git a/ps3/main.c b/ps3/main.c index 72bf64d168..771c0060a9 100644 --- a/ps3/main.c +++ b/ps3/main.c @@ -177,7 +177,7 @@ static void init_settings(void) { if(!file_exists(SYS_CONFIG_FILE)) { - SSNES_ERR("Config file \"%s\" doesn't exist! Creating...\n", SYS_CONFIG_FILE); + SSNES_ERR("Config file \"%s\" doesn't exist. Creating...\n", SYS_CONFIG_FILE); FILE * f; f = fopen(SYS_CONFIG_FILE, "w"); fclose(f); @@ -263,7 +263,7 @@ static void save_settings(void) config_set_int(conf, "audio_mute", g_extern.audio_data.mute); if (!config_file_write(conf, SYS_CONFIG_FILE)) - SSNES_ERR("Failed to write config file to \"%s\"! Check permissions!\n", SYS_CONFIG_FILE); + SSNES_ERR("Failed to write config file to \"%s\". Check permissions.\n", SYS_CONFIG_FILE); free(conf); } diff --git a/ps3/ps3_video_psgl.c b/ps3/ps3_video_psgl.c index 237537d956..339f205da6 100644 --- a/ps3/ps3_video_psgl.c +++ b/ps3/ps3_video_psgl.c @@ -825,7 +825,7 @@ static void gl_update_resize(void) GLenum status = glCheckFramebufferStatusOES(GL_FRAMEBUFFER_OES); if (status != GL_FRAMEBUFFER_COMPLETE_OES) - SSNES_WARN("Failed to reinit FBO texture!\n"); + SSNES_WARN("Failed to reinit FBO texture.\n"); SSNES_LOG("Recreating FBO texture #%d: %ux%u\n", i, gl->fbo_rect[i].width, gl->fbo_rect[i].height); } diff --git a/settings.c b/settings.c index 4261074186..fc6e095903 100644 --- a/settings.c +++ b/settings.c @@ -486,7 +486,7 @@ bool config_load_file(const char *path) fill_pathname_dir(g_extern.savefile_name_srm, g_extern.basename, ".srm", sizeof(g_extern.savefile_name_srm)); } else - SSNES_WARN("savefile_directory is not a directory, ignoring ...!\n"); + SSNES_WARN("savefile_directory is not a directory, ignoring ....\n"); } if (!g_extern.has_set_state_path && config_get_array(conf, "savestate_directory", tmp_str, sizeof(tmp_str))) { diff --git a/ssnes.c b/ssnes.c index 28e188419d..87929baa2d 100644 --- a/ssnes.c +++ b/ssnes.c @@ -116,7 +116,7 @@ static void take_screenshot(void) const char *msg = NULL; if (ret) { - SSNES_LOG("Taking screenshot!\n"); + SSNES_LOG("Taking screenshot.\n"); msg = "Taking screenshot."; } else @@ -823,7 +823,7 @@ static void parse_input(int argc, char *argv[]) g_extern.sram_save_disable = true; else if (strcmp(optarg, "load-save") != 0) { - SSNES_ERR("Invalid argument in --sram-mode!\n"); + SSNES_ERR("Invalid argument in --sram-mode.\n"); print_help(); ssnes_fail(1, "parse_input()"); } @@ -1150,13 +1150,13 @@ static void init_rewind(void) if (!g_extern.state_buf) { - SSNES_ERR("Failed to allocate memory for rewind buffer!\n"); + SSNES_ERR("Failed to allocate memory for rewind buffer.\n"); return; } if (!psnes_serialize((uint8_t*)g_extern.state_buf, g_extern.state_size)) { - SSNES_ERR("Failed to perform initial serialization for rewind!\n"); + SSNES_ERR("Failed to perform initial serialization for rewind.\n"); free(g_extern.state_buf); g_extern.state_buf = NULL; return; @@ -1166,7 +1166,7 @@ static void init_rewind(void) g_extern.state_manager = state_manager_new(aligned_state_size, g_settings.rewind_buffer_size, g_extern.state_buf); if (!g_extern.state_manager) - SSNES_WARN("Failed to init rewind buffer. Rewinding will be disabled!\n"); + SSNES_WARN("Failed to init rewind buffer. Rewinding will be disabled.\n"); } static void deinit_rewind(void) @@ -1184,13 +1184,13 @@ static void init_movie(void) g_extern.bsv.movie = bsv_movie_init(g_extern.bsv.movie_start_path, SSNES_MOVIE_PLAYBACK); if (!g_extern.bsv.movie) { - SSNES_ERR("Failed to load movie file: \"%s\"!\n", g_extern.bsv.movie_start_path); + SSNES_ERR("Failed to load movie file: \"%s\".\n", g_extern.bsv.movie_start_path); ssnes_fail(1, "init_movie()"); } g_extern.bsv.movie_playback = true; msg_queue_push(g_extern.msg_queue, "Starting movie playback.", 2, 180); - SSNES_LOG("Starting movie playback!\n"); + SSNES_LOG("Starting movie playback.\n"); g_settings.rewind_granularity = 1; } else if (g_extern.bsv.movie_start_recording) @@ -1206,11 +1206,11 @@ static void init_movie(void) if (g_extern.bsv.movie) { - SSNES_LOG("Starting movie record to \"%s\"!\n", g_extern.bsv.movie_start_path); + SSNES_LOG("Starting movie record to \"%s\".\n", g_extern.bsv.movie_start_path); g_settings.rewind_granularity = 1; } else - SSNES_ERR("Failed to start movie record!\n"); + SSNES_ERR("Failed to start movie record.\n"); } } @@ -1723,7 +1723,7 @@ static void check_movie_record(void) { msg_queue_clear(g_extern.msg_queue); msg_queue_push(g_extern.msg_queue, "Stopping movie record.", 2, 180); - SSNES_LOG("Stopping movie record!\n"); + SSNES_LOG("Stopping movie record.\n"); bsv_movie_free(g_extern.bsv.movie); g_extern.bsv.movie = NULL; } @@ -1751,9 +1751,9 @@ static void check_movie_record(void) msg_queue_push(g_extern.msg_queue, g_extern.bsv.movie ? msg : "Failed to start movie record.", 1, 180); if (g_extern.bsv.movie) - SSNES_LOG("Starting movie record to \"%s\"!\n", path); + SSNES_LOG("Starting movie record to \"%s\".\n", path); else - SSNES_ERR("Failed to start movie record!\n"); + SSNES_ERR("Failed to start movie record.\n"); } } @@ -1765,7 +1765,7 @@ static void check_movie_playback(void) if (g_extern.bsv.movie_end) { msg_queue_push(g_extern.msg_queue, "Movie playback ended.", 1, 180); - SSNES_LOG("Movie playback ended!\n"); + SSNES_LOG("Movie playback ended.\n"); bsv_movie_free(g_extern.bsv.movie); g_extern.bsv.movie = NULL; @@ -1794,18 +1794,18 @@ static void check_pause(void) if (g_extern.is_paused) { - SSNES_LOG("Paused!\n"); + SSNES_LOG("Paused.\n"); if (driver.audio_data) driver.audio->stop(driver.audio_data); } else { - SSNES_LOG("Unpaused!\n"); + SSNES_LOG("Unpaused.\n"); if (driver.audio_data) { if (!driver.audio->start(driver.audio_data)) { - SSNES_ERR("Failed to resume audio driver! Will continue without audio!\n"); + SSNES_ERR("Failed to resume audio driver. Will continue without audio.\n"); g_extern.audio_active = false; } } @@ -1813,20 +1813,20 @@ static void check_pause(void) } else if (focus && !old_focus) { - SSNES_LOG("Unpaused!\n"); + SSNES_LOG("Unpaused.\n"); g_extern.is_paused = false; if (driver.audio_data) { if (!driver.audio->start(driver.audio_data)) { - SSNES_ERR("Failed to resume audio driver! Will continue without audio!\n"); + SSNES_ERR("Failed to resume audio driver. Will continue without audio.\n"); g_extern.audio_active = false; } } } else if (!focus && old_focus) { - SSNES_LOG("Paused!\n"); + SSNES_LOG("Paused.\n"); g_extern.is_paused = true; if (driver.audio_data) driver.audio->stop(driver.audio_data); @@ -1852,7 +1852,7 @@ static void check_oneshot(void) void ssnes_game_reset(void) { - SSNES_LOG("Resetting game!\n"); + SSNES_LOG("Resetting game.\n"); msg_queue_clear(g_extern.msg_queue); msg_queue_push(g_extern.msg_queue, "Reset.", 1, 120); psnes_reset(); @@ -1909,7 +1909,7 @@ static void check_shader_dir(void) SSNES_LOG("Applying shader \"%s\"\n", shader); if (!driver.video->xml_shader(driver.video_data, shader)) - SSNES_WARN("Failed to apply shader!\n"); + SSNES_WARN("Failed to apply shader.\n"); } old_pressed_next = pressed_next; @@ -2135,7 +2135,7 @@ int ssnes_main_init(int argc, char *argv[]) if (!g_extern.sram_load_disable) load_save_files(); else - SSNES_LOG("Skipping SRAM load!\n"); + SSNES_LOG("Skipping SRAM load.\n"); init_movie(); @@ -2163,7 +2163,7 @@ int ssnes_main_init(int argc, char *argv[]) #endif if (!g_extern.use_sram) - SSNES_LOG("SRAM will not be saved!\n"); + SSNES_LOG("SRAM will not be saved.\n"); if (g_extern.use_sram) init_autosave(); diff --git a/tools/ssnes-joyconfig.c b/tools/ssnes-joyconfig.c index ce5936b63d..7b8ce50121 100644 --- a/tools/ssnes-joyconfig.c +++ b/tools/ssnes-joyconfig.c @@ -164,7 +164,7 @@ static void get_binds(config_file_t *conf, int player, int joypad) break; case SDL_JOYAXISMOTION: - if ( // This is starting to look like Lisp! :D + if ( // This is starting to look like Lisp. :D (abs((int)event.jaxis.value - initial_axes[event.jaxis.axis]) > 20000) && ( (event.jaxis.axis != last_axis) || @@ -270,7 +270,7 @@ static void parse_input(int argc, char *argv[]) g_joypad = strtol(optarg, NULL, 0); if (g_joypad < 0) { - fprintf(stderr, "Joypad number can't be negative!\n"); + fprintf(stderr, "Joypad number can't be negative.\n"); exit(1); } break; @@ -279,7 +279,7 @@ static void parse_input(int argc, char *argv[]) g_player = strtol(optarg, NULL, 0); if (g_player < 1) { - fprintf(stderr, "Player number must be at least 1!\n"); + fprintf(stderr, "Player number must be at least 1.\n"); exit(1); } else if (g_player > MAX_PLAYERS)