aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/undo.c
Commit message (Collapse)AuthorAge
...
| * API: Implement buffer updatesPeter Hodge2018-05-23
|/ | | | | Originally written by @phodge in https://github.com/neovim/neovim/pull/5269.
* undo: Silence PVS/V547: expression may be false on other systemZyX2018-04-22
|
* vim-patch:8.0.0448: some macros are lower case (#7936)KunMing Xie2018-01-30
| | | | | | | Problem: Some macros are in lower case, which can be confusing. Solution: Make a few lower case macros upper case. https://github.com/vim/vim/commit/b5aedf3e228d35821591da9ae8501b61cf2e264c ref #6297
* *: Provide list length when allocating listsZyX2018-01-14
|
* vim-patch:8.0.0074Michael Schupikov2017-12-15
| | | | | | | | | | Problem: Cannot make Vim fail on an internal error. Solution: Add IEMSG() and IEMSG2(). (Domenique Pelle) Avoid reporting an internal error without mentioning where. https://github.com/vim/vim/commit/95f096030ed1a8afea028f2ea295d6f6a70f466f Signed-off-by: Michael Schupikov <michael@schupikov.de>
* vim-patch:8.0.0149 (#7127)KunMing Xie2017-08-08
| | | | | | | | | Problem: ":earlier" and ":later" do not work after startup or reading the undo file. Solution: Use absolute time stamps instead of relative to the Vim start time. (Christian Brabandt, Pavel Juhas, closes vim/vim#1300, closes vim/vim#1254) https://github.com/vim/vim/commit/cbd4de44e8d08fba3c09eb40ad6e36e83faf020a
* bufhl: fix moveBjörn Linse2017-06-24
|
* *: Add comment to all C filesZyX2017-04-19
|
* vim-patch:8.0.0378James McCoy2017-04-09
| | | | | | | | | Problem: Another possible overflow when reading corrupted undo file. Solution: Check if allocated size is not too big. (King) https://github.com/vim/vim/commit/0c8485f0e4931463c0f7986e1ea84a7d79f10c75 CVE-2017-6350
* vim-patch:8.0.0377James McCoy2017-04-09
| | | | | | | | | Problem: Possible overflow when reading corrupted undo file. Solution: Check if allocated size is not too big. (King) https://github.com/vim/vim/commit/3eb1637b1bba19519885dd6d377bd5596e91d22c CVE-2017-6349
* eval: Move remaining get_tv_string* functions to eval/typval.cZyX2017-03-29
|
* eval,*: Move get_tv_string to typval.cZyX2017-03-29
| | | | Function was renamed and changed to return `const char *`.
* eval: Split and move dict_add_nr_str to typval.cZyX2017-03-29
| | | | Function was split into tv_dict_add_nr() and tv_dict_add_str().
* eval: Move dict_add_list and dict_add_dict to typval.cZyX2017-03-29
|
* *: Move some dictionary functions to typval.h and use char*ZyX2017-03-29
| | | | Also fixes buffer reusage in setmatches() and complete().
* eval: Split eval.c into smaller filesZyX2017-03-29
|
* terminal: 'scrollback'Justin M. Keyes2017-02-26
| | | | Closes #2637
* terminal: Allow undo and 'modifiable'.Justin M. Keyes2017-02-26
| | | | | | | Partial step towards #2637. Will crash if *all* lines are deleted. Closes #2607 References #5431
* *: Fix linter errorsZyX2017-02-15
|
* *: Partial string handling refactoringZyX2017-02-15
| | | | | | | | Main points: - Replace `char_u` with `char` in some cases. - Remove `str[len] = NUL` hack in some cases when `str` may be considered `const`.
* Merge pull request #5869 from hardenedapple/undojoin-curheadJames McCoy2017-02-02
|\ | | | | Don't set `b_u_curhead` in `ex_undojoin()`
| * Don't set b_u_curhead in ex_undojoin()Matthew Malcomson2017-01-22
| | | | | | | | | | vim-patch:8.0.0205 This provides no benefit, and introduces some bugs.
* | undo: :earlier, g-: Set b_u_seq_cur correctly. (#6016)Matthew Malcomson2017-01-31
|/ | | | | | | | | | | | | | | | | | | Previously alternate branches were not accounted for properly, with this change g- after an undo to a branch point works. The current sequence number b_u_seq_cur is used in undo_time(), in u_doit() this was calculated by subtracting one from the curhead sequence number. The curhead header entry represents the change that was just undone, so the sequence number we want is that of the change we have moved to. This is the sequence number of the undo head that is the uh_next element of this curhead. That sequence number is not always one less than the curhead sequence number -- there may have been an alternate branch at this point. Instead of subtracting one, we now directly find the sequence number of curhead->uh_next.
* Bump all nvim-specific error codes above E5000James McCoy2016-11-15
| | | | | | | | | | In order to not conflict with new error codes that Vim adds, all Neovim error codes should be above 5000. The three existing sub-5000 error codes (E926, E951, and E952) are now E50003, E5004, and E5005 respectively. E953 was removed in 6167ce6df2753d5474ad49aea19f5957128ab015, so just remove it from the help.
* 'inccommand': buftype=nofile, restore cursor/viewJustin M. Keyes2016-11-10
| | | | | | | - Use a standard scratch buffer instead of a new 'buftype', functions like curbufIsChanged() already have special handling for scratch bufs. - Cleanup some stuff from the previous merge. - Add support for :smagic, :snomagic. Closes #5578
* lintJustin M. Keyes2016-11-08
|
* 'inccommand': reworkJustin M. Keyes2016-11-08
| | | | | | | | | | | | | | | | | - Eliminate/isolate static/global variables - Remove special-case parameter from buflist_new() - Remove special-case ECMD_RESERVED_BUFNR - To determine when u_undo_and_forget() should be done, check b_changedtick instead of a heuristic. - use mb_string2cells() instead of strlen() to measure the :sub patterns - call ml_close() before buf_clear_file(). Avoids leaks caught by ASan. Original patch by: Robin Elrharbi-Fleury (Robinhola) Audrey Rayé (Adrey06) Philémon Hullot (DesbyP) Aymeric Collange (aym7) Clément Guyomard (Clement0)
* Incsubsitution featureKillTheMule2016-10-30
| | | | | | | | | | | | | | | | | Originally implemented by * Clement0 * DesbyP * aym7 * Adrey06 * Robinhola in #4811. Major reworkings and bug fixes by * bfredl Most tests suggested by ZyX-l, suggestions for improvements by oni-link.
* refactor: eliminate misc2.cJustin M. Keyes2016-09-13
| | | | | | | | | | move `call_shell` to misc1.c Move some fns to state.c Move some fns to option.c Move some fns to memline.c Move `vim_chdir*` fns to file_search.c Move some fns to new module, bytes.c Move some fns to fileio.c
* os/fs: Rename os_file_exists to os_path_exists (#4973)Daniel Xu2016-07-06
| | | | Because the old name did not indicate that the function would return true on directories as well.
* *: Fix new linter errorsZyX2016-05-01
| | | | Originally there were 128 new errors, so I thought this is a good idea to fix all of them. Of course, this commit also fixes many suppressed errors.
* vim-patch:7.4.1574Florent FAYOLLE2016-03-18
| | | | | | | Problem: ":undo 0" does not work. (Florent Fayolle) Solution: Make it undo all the way. (closes vim/vim#688) https://github.com/vim/vim/commit/d22e9465f6228207a4fe722ee84371c7817060d6
* Fix the ASCII-art diagram in undo.cFelipe Oliveira Carvalho2016-02-24
| | | | Set \t to 8 spaces and `retab`.
* vim-patch:7.4.634watiko2016-02-01
| | | | | | | | Problem: Marks are not restored after redo + undo. Solution: Fix the way marks are restored. (Olaf Dabrunz) https://github.com/vim/vim/commit/f65aad5554f1d1f972f0bd38059da70e3cdf4c87 https://github.com/vim/vim/commit/35e7594dd429f7a8a06cefd61c3e8d48b9bd74e2
* Windows: Include <fcntl.h> for file constants.Seth Jackson2016-01-17
| | | | | | This header is required by POSIX for the constants (O_RDONLY, etc.) but we were only including it on Unix systems as a side effect of including <unistd.h>.
* undo.c: Change return type to bool on functions #3697Wayne Rowcliffe2015-12-01
| | | | | | | Update some comments, too. Reviewed-by: Björn Linse <bjorn.linse@gmail.com> Reviewed-by: Michael Reed <Pyrohh@users.noreply.github.com>
* src/*: Remove `VIM - Vi improved ...` headerMichael Reed2015-11-27
| | | | | | | | | | | | | | | | | | | Regarding the individual items in the header: `Vim - Vi improved by Bram Moolenar` Bram Moolenar is already mentioned throughout the documentation, as well as the intro screen. `:help uganda` It's already shown to all users who don't use `shortmess+=I` upon starting nvim, and is already placed prominently in help.txt, i.e., `:help` run with no arguments. `:help credits` Already mentioned near the top of help.txt. `README.md` Already mentioned in develop.txt.
* Remove unnecessary includes for errno.hRui Abreu Ferreira2015-11-25
|
* src: README.txt -> README.mdMichael Reed2015-11-23
| | | | | The former no longer exists in this repo; see the top of src/nvim/README.md.
* undo: Remove incorrect NONNULL_ALL attributeZyX2015-11-05
| | | Fixes #3605
* undo: Automatically create undo directory if neededZyX2015-10-29
|
* undo: Do some refactoringZyX2015-10-29
| | | | | | Specifically refactor u_get_undo_file_name which will be modified to automatically create undo directory and replace `char_u` with `char` in some of the related functions.
* undo: When reading persistent undo file give marks current timeZyX2015-10-08
| | | | | Guess this is better then zero time which will give ShaDa marks the priority almost always.
* *: Make ShaDa code use VimL values for additional_\* dataZyX2015-10-08
|
* viminfo: First version of ShaDa file dumpingZyX2015-10-08
| | | | | | | | | | | | | | | | | | | | What works: 1. ShaDa file dumping: header, registers, jump list, history, search patterns, substitute strings, variables. 2. ShaDa file reading: registers, global marks, variables. Most was not tested. TODO: 1. Merging. 2. Reading history, local marks, jump and buffer lists. 3. Documentation update. 4. Converting some data from &encoding. 5. Safer variant of dumping viminfo (dump to temporary file then rename). 6. Removing old viminfo code (currently masked with `#if 0` in a ShaDa file for reference).
* Remove instances of TRUE/FALSE macroSteven Oliver2015-09-04
| | | | | | memory.c os_unix.c path.c
* fix strict-overflow cases #3236Nikolay Orlyuk2015-08-25
|
* Remove char_u: message:smsg()Michael Reed2015-05-13
|
* Merge #2470: Remove char_u (5)Eliseo Martínez2015-05-07
|\ | | | | | | | | | | Reviewed-by: Scott Prager <splinterofchaos@gmail.com> Reviewed-by: Michael Reed <m.reed@mykolab.com> Reviewed-by: Eliseo Martínez <eliseomarmol@gmail.com>
| * Remove char_u: concat_fnames()Mark Bainter2015-05-06
| |