mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
Merge pull request #3607 from ZyX-I/fix-3605
undo: Remove incorrect NONNULL_ALL attribute
This commit is contained in:
commit
dd087ea9c9
@ -650,7 +650,7 @@ void u_compute_hash(char_u *hash)
|
|||||||
///
|
///
|
||||||
/// @return [allocated] File name to read from/write to or NULL.
|
/// @return [allocated] File name to read from/write to or NULL.
|
||||||
char *u_get_undo_file_name(const char *const buf_ffname, const bool reading)
|
char *u_get_undo_file_name(const char *const buf_ffname, const bool reading)
|
||||||
FUNC_ATTR_NONNULL_ALL FUNC_ATTR_WARN_UNUSED_RESULT
|
FUNC_ATTR_WARN_UNUSED_RESULT
|
||||||
{
|
{
|
||||||
char *dirp;
|
char *dirp;
|
||||||
char dir_name[MAXPATHL + 1];
|
char dir_name[MAXPATHL + 1];
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
-- Specs for
|
-- Specs for :wundo and underlying functions
|
||||||
-- :wundo
|
|
||||||
|
|
||||||
local helpers = require('test.functional.helpers')
|
local helpers = require('test.functional.helpers')
|
||||||
local execute, eq, clear, eval, feed =
|
local execute, clear, eval, feed, spawn, nvim_prog, set_session =
|
||||||
helpers.execute, helpers.eq, helpers.clear, helpers.eval, helpers.feed
|
helpers.execute, helpers.clear, helpers.eval, helpers.feed, helpers.spawn,
|
||||||
|
helpers.nvim_prog, helpers.set_session
|
||||||
|
|
||||||
|
|
||||||
describe(':wundo', function()
|
describe(':wundo', function()
|
||||||
@ -16,5 +16,14 @@ describe(':wundo', function()
|
|||||||
|
|
||||||
os.remove(eval('getcwd()') .. '/foo') --cleanup
|
os.remove(eval('getcwd()') .. '/foo') --cleanup
|
||||||
end)
|
end)
|
||||||
|
end)
|
||||||
|
|
||||||
|
describe('u_* functions', function()
|
||||||
|
it('safely fail on new, non-empty buffer', function()
|
||||||
|
local session = spawn({nvim_prog, '-u', 'NONE', '-i', 'NONE', '--embed',
|
||||||
|
'-c', 'set undodir=. undofile'})
|
||||||
|
set_session(session)
|
||||||
|
execute('echo "True"') -- Should not error out due to crashed Neovim
|
||||||
|
session:exit(0)
|
||||||
|
end)
|
||||||
end)
|
end)
|
||||||
|
Loading…
Reference in New Issue
Block a user