aboutsummaryrefslogtreecommitdiff
path: root/src/ex_cmds.c
diff options
context:
space:
mode:
authorThiago de Arruda <tpadilha84@gmail.com>2014-03-13 12:11:03 -0300
committerThiago de Arruda <tpadilha84@gmail.com>2014-03-13 15:26:28 -0300
commitf6ace9962d95eb12236083871154c1501f02c556 (patch)
treef9a1d5b6ca8eaa68114c98dcd92c6161bc15454d /src/ex_cmds.c
parent3cac32e49c7fae9cf5963d35f3fd3052c061b2fa (diff)
downloadrneovim-f6ace9962d95eb12236083871154c1501f02c556.tar.gz
rneovim-f6ace9962d95eb12236083871154c1501f02c556.tar.bz2
rneovim-f6ace9962d95eb12236083871154c1501f02c556.zip
Refactor travis build to use clang's sanitizers
- Valgrind configuration removed - Fix errors reported by the undefined behavior sanitizer - Travis will now run two build steps: - A normal build of a shared library for unit testing(in parallel with gcc) - A clang build with some sanitizers enabled for integration testing. After these changes travis will run much faster, while providing valgrind-like error detection.
Diffstat (limited to 'src/ex_cmds.c')
-rw-r--r--src/ex_cmds.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/ex_cmds.c b/src/ex_cmds.c
index 68b5727786..c4da8d65e7 100644
--- a/src/ex_cmds.c
+++ b/src/ex_cmds.c
@@ -2834,8 +2834,10 @@ do_ecmd (
* <VN> We could instead free the synblock
* and re-attach to buffer, perhaps.
*/
- if (curwin->w_s == &(curwin->w_buffer->b_s))
+ if (curwin->w_buffer != NULL &&
+ curwin->w_s == &(curwin->w_buffer->b_s))
curwin->w_s = &(buf->b_s);
+
curwin->w_buffer = buf;
curbuf = buf;
++curbuf->b_nwindows;