diff options
Diffstat (limited to 'src/nvim/os')
-rw-r--r-- | src/nvim/os/dl.c | 4 | ||||
-rw-r--r-- | src/nvim/os/env.c | 12 | ||||
-rw-r--r-- | src/nvim/os/fileio.c | 2 | ||||
-rw-r--r-- | src/nvim/os/fs.c | 6 | ||||
-rw-r--r-- | src/nvim/os/shell.c | 16 | ||||
-rw-r--r-- | src/nvim/os/users.c | 2 |
6 files changed, 21 insertions, 21 deletions
diff --git a/src/nvim/os/dl.c b/src/nvim/os/dl.c index b2e3994d10..7d095d31e3 100644 --- a/src/nvim/os/dl.c +++ b/src/nvim/os/dl.c @@ -49,7 +49,7 @@ bool os_libcall(const char *libname, const char *funcname, const char *argv, int // open the dynamic loadable library if (uv_dlopen(libname, &lib)) { - EMSG2(_("dlerror = \"%s\""), uv_dlerror(&lib)); + semsg(_("dlerror = \"%s\""), uv_dlerror(&lib)); uv_dlclose(&lib); return false; } @@ -57,7 +57,7 @@ bool os_libcall(const char *libname, const char *funcname, const char *argv, int // find and load the requested function in the library gen_fn fn; if (uv_dlsym(&lib, funcname, (void **)&fn)) { - EMSG2(_("dlerror = \"%s\""), uv_dlerror(&lib)); + semsg(_("dlerror = \"%s\""), uv_dlerror(&lib)); uv_dlclose(&lib); return false; } diff --git a/src/nvim/os/env.c b/src/nvim/os/env.c index 0f363ecfc3..727b10f7a7 100644 --- a/src/nvim/os/env.c +++ b/src/nvim/os/env.c @@ -250,7 +250,7 @@ void os_copy_fullenv(char **env, size_t env_size) char *utf8_str; int conversion_result = utf16_to_utf8(p, -1, &utf8_str); if (conversion_result != 0) { - EMSG2("utf16_to_utf8 failed: %d", conversion_result); + semsg("utf16_to_utf8 failed: %d", conversion_result); break; } p += l + 1; @@ -297,7 +297,7 @@ char *os_getenvname_at_index(size_t index) char *utf8_str; int conversion_result = utf16_to_utf8(p, -1, &utf8_str); if (conversion_result != 0) { - EMSG2("utf16_to_utf8 failed: %d", conversion_result); + semsg("utf16_to_utf8 failed: %d", conversion_result); break; } @@ -375,7 +375,7 @@ void os_get_hostname(char *hostname, size_t size) if (GetComputerNameW(host_utf16, &host_wsize) == 0) { *hostname = '\0'; DWORD err = GetLastError(); - EMSG2("GetComputerNameW failed: %d", err); + semsg("GetComputerNameW failed: %d", err); return; } host_utf16[host_wsize] = '\0'; @@ -383,13 +383,13 @@ void os_get_hostname(char *hostname, size_t size) char *host_utf8; int conversion_result = utf16_to_utf8(host_utf16, -1, &host_utf8); if (conversion_result != 0) { - EMSG2("utf16_to_utf8 failed: %d", conversion_result); + semsg("utf16_to_utf8 failed: %d", conversion_result); return; } xstrlcpy(hostname, host_utf8, size); xfree(host_utf8); #else - EMSG("os_get_hostname failed: missing uname()"); + emsg("os_get_hostname failed: missing uname()"); *hostname = '\0'; #endif } @@ -481,7 +481,7 @@ void init_homedir(void) var = (char *)IObuff; } if (os_chdir(os_buf) != 0) { - EMSG(_(e_prev_dir)); + emsg(_(e_prev_dir)); } } } diff --git a/src/nvim/os/fileio.c b/src/nvim/os/fileio.c index 1ae6ca4244..b1710737d0 100644 --- a/src/nvim/os/fileio.c +++ b/src/nvim/os/fileio.c @@ -426,6 +426,6 @@ int msgpack_file_write(void *data, const char *buf, size_t len) /// @return -1 (error return for msgpack_packer callbacks). int msgpack_file_write_error(const int error) { - emsgf(_("E5420: Failed to write to file: %s"), os_strerror(error)); + semsg(_("E5420: Failed to write to file: %s"), os_strerror(error)); return -1; } diff --git a/src/nvim/os/fs.c b/src/nvim/os/fs.c index 9675cfbb0f..3ff13c2b3f 100644 --- a/src/nvim/os/fs.c +++ b/src/nvim/os/fs.c @@ -1212,7 +1212,7 @@ char *os_resolve_shortcut(const char *fname) wchar_t *p; const int r = utf8_to_utf16(fname, -1, &p); if (r != 0) { - EMSG2("utf8_to_utf16 failed: %d", r); + semsg("utf8_to_utf16 failed: %d", r); } else if (p != NULL) { // Get a pointer to the IPersistFile interface. hr = pslw->lpVtbl->QueryInterface(pslw, &IID_IPersistFile, (void **)&ppf); @@ -1239,7 +1239,7 @@ char *os_resolve_shortcut(const char *fname) if (hr == S_OK && wsz[0] != NUL) { const int r2 = utf16_to_utf8(wsz, -1, &rfname); if (r2 != 0) { - EMSG2("utf16_to_utf8 failed: %d", r2); + semsg("utf16_to_utf8 failed: %d", r2); } } @@ -1274,7 +1274,7 @@ bool os_is_reparse_point_include(const char *path) const int r = utf8_to_utf16(path, -1, &utf16_path); if (r != 0) { - EMSG2("utf8_to_utf16 failed: %d", r); + semsg("utf8_to_utf16 failed: %d", r); return false; } diff --git a/src/nvim/os/shell.c b/src/nvim/os/shell.c index 2bff65b241..6ef0aa1091 100644 --- a/src/nvim/os/shell.c +++ b/src/nvim/os/shell.c @@ -159,7 +159,7 @@ int os_expand_wildcards(int num_pat, char_u **pat, int *num_file, char_u ***file // get a name for the temp file if ((tempname = vim_tempname()) == NULL) { - EMSG(_(e_notmp)); + emsg(_(e_notmp)); return FAIL; } @@ -341,7 +341,7 @@ int os_expand_wildcards(int num_pat, char_u **pat, int *num_file, char_u ***file if (!(flags & EW_SILENT)) { msg_putchar('\n'); // clear bottom line quickly cmdline_row = Rows - 1; // continue on last line - MSG(_(e_wildexpand)); + msg(_(e_wildexpand)); msg_start(); // don't overwrite this message } @@ -358,7 +358,7 @@ int os_expand_wildcards(int num_pat, char_u **pat, int *num_file, char_u ***file if (fd == NULL) { // Something went wrong, perhaps a file name with a special char. if (!(flags & EW_SILENT)) { - MSG(_(e_wildexpand)); + msg(_(e_wildexpand)); msg_start(); // don't overwrite this message } xfree(tempname); @@ -389,7 +389,7 @@ int os_expand_wildcards(int num_pat, char_u **pat, int *num_file, char_u ***file os_remove((char *)tempname); if (readlen != len) { // unexpected read error - EMSG2(_(e_notread), tempname); + semsg(_(e_notread), tempname); xfree(tempname); xfree(buffer); return FAIL; @@ -670,7 +670,7 @@ int os_call_shell(char_u *cmd, ShellOpts opts, char_u *extra_args) } if (!emsg_silent && exitcode != 0 && !(opts & kShellOptSilent)) { - MSG_PUTS(_("\nshell returned ")); + msg_puts(_("\nshell returned ")); msg_outnum(exitcode); msg_putchar('\n'); } @@ -742,9 +742,9 @@ static int do_os_system(char **argv, const char *input, size_t len, char **outpu loop_poll_events(&main_loop, 0); // Failed, probably 'shell' is not executable. if (!silent) { - MSG_PUTS(_("\nshell failed to start: ")); + msg_puts(_("\nshell failed to start: ")); msg_outtrans((char_u *)os_strerror(status)); - MSG_PUTS(": "); + msg_puts(": "); msg_outtrans((char_u *)prog); msg_putchar('\n'); } @@ -1180,7 +1180,7 @@ static void shell_write_cb(Stream *stream, void *data, int status) if (status) { // Can happen if system() tries to send input to a shell command that was // backgrounded (:call system("cat - &", "foo")). #3529 #5241 - msg_schedule_emsgf(_("E5677: Error writing input to shell-command: %s"), + msg_schedule_semsg(_("E5677: Error writing input to shell-command: %s"), uv_err_name(status)); } stream_close(stream, NULL, NULL); diff --git a/src/nvim/os/users.c b/src/nvim/os/users.c index fd7ead68da..9952e2b387 100644 --- a/src/nvim/os/users.c +++ b/src/nvim/os/users.c @@ -64,7 +64,7 @@ int os_get_usernames(garray_T *users) char *user; int conversion_result = utf16_to_utf8(uinfo[i].usri0_name, -1, &user); if (conversion_result != 0) { - EMSG2("utf16_to_utf8 failed: %d", conversion_result); + semsg("utf16_to_utf8 failed: %d", conversion_result); break; } add_user(users, user, false); |