diff options
author | Justin M. Keyes <justinkz@gmail.com> | 2019-02-14 05:49:35 +0100 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2019-02-14 05:49:35 +0100 |
commit | b7f518cbfad2082e972b6e1bd0cac2b9e76f1b45 (patch) | |
tree | 56c36ec2cc58a0c1e775b57275abc8240195528f | |
parent | 969cc55993919530b2a96e30f02fe71711cab28a (diff) | |
download | rneovim-b7f518cbfad2082e972b6e1bd0cac2b9e76f1b45.tar.gz rneovim-b7f518cbfad2082e972b6e1bd0cac2b9e76f1b45.tar.bz2 rneovim-b7f518cbfad2082e972b6e1bd0cac2b9e76f1b45.zip |
PVS/V1028: cast operands, not the result
-rw-r--r-- | src/nvim/garray.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/nvim/garray.c b/src/nvim/garray.c index 2d2af54c95..74fd9d89cb 100644 --- a/src/nvim/garray.c +++ b/src/nvim/garray.c @@ -91,8 +91,8 @@ void ga_grow(garray_T *gap, int n) } int new_maxlen = gap->ga_len + n; - size_t new_size = (size_t)(gap->ga_itemsize * new_maxlen); - size_t old_size = (size_t)(gap->ga_itemsize * gap->ga_maxlen); + size_t new_size = (size_t)gap->ga_itemsize * (size_t)new_maxlen; + size_t old_size = (size_t)gap->ga_itemsize * (size_t)gap->ga_maxlen; // reallocate and clear the new memory char *pp = xrealloc(gap->ga_data, new_size); |