diff options
author | Bram Moolenaar <Bram@vim.org> | 2019-05-24 19:39:03 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2019-05-24 19:39:03 +0200 |
commit | 18a4ba29aeccb9841d5bfdd2eaaffdfae2f15ced (patch) | |
tree | 408ad339f6b34876d2fa481ac61568c7739b1160 /src/ui.c | |
parent | 71de720c2c117137185a6fc233b35aab37f0d4bc (diff) | |
download | vim-git-18a4ba29aeccb9841d5bfdd2eaaffdfae2f15ced.tar.gz |
patch 8.1.1386: unessesary type casts for lalloc()v8.1.1386
Problem: Unessesary type casts for lalloc().
Solution: Remove type casts. Change lalloc(size, TRUE) to alloc(size).
Diffstat (limited to 'src/ui.c')
-rw-r--r-- | src/ui.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -1514,7 +1514,7 @@ clip_copy_modeless_selection(int both UNUSED) len *= 2; /* max. 2 bytes per display cell */ else if (enc_utf8) len *= MB_MAXBYTES; - buffer = lalloc((long_u)len, TRUE); + buffer = alloc(len); if (buffer == NULL) /* out of memory */ return; @@ -1897,11 +1897,11 @@ get_input_buf(void) garray_T *gap; /* We use a growarray to store the data pointer and the length. */ - gap = (garray_T *)alloc((unsigned)sizeof(garray_T)); + gap = (garray_T *)alloc(sizeof(garray_T)); if (gap != NULL) { /* Add one to avoid a zero size. */ - gap->ga_data = alloc((unsigned)inbufcount + 1); + gap->ga_data = alloc(inbufcount + 1); if (gap->ga_data != NULL) mch_memmove(gap->ga_data, inbuf, (size_t)inbufcount); gap->ga_len = inbufcount; |