0
0
mirror of https://github.com/vim/vim.git synced 2025-09-23 03:43:49 -04:00

patch 8.1.0703: compiler warnings with 64-bit compiler

Problem:    Compiler warnings with 64-bit compiler.
Solution:   Change types, add type casts. (Mike Williams)
This commit is contained in:
Bram Moolenaar
2019-01-08 20:14:35 +01:00
parent b589f95b38
commit 8aef43b66c
3 changed files with 9 additions and 6 deletions

View File

@@ -1205,9 +1205,10 @@ serialize_header(bufinfo_T *bi, char_u *hash)
/* buffer-specific data */
undo_write_bytes(bi, (long_u)buf->b_ml.ml_line_count, 4);
len = buf->b_u_line_ptr.ul_line == NULL
? 0 : STRLEN(buf->b_u_line_ptr.ul_line);
? 0L : (long)STRLEN(buf->b_u_line_ptr.ul_line);
undo_write_bytes(bi, (long_u)len, 4);
if (len > 0 && fwrite_crypt(bi, buf->b_u_line_ptr.ul_line, (size_t)len) == FAIL)
if (len > 0 && fwrite_crypt(bi, buf->b_u_line_ptr.ul_line, (size_t)len)
== FAIL)
return FAIL;
undo_write_bytes(bi, (long_u)buf->b_u_line_lnum, 4);
undo_write_bytes(bi, (long_u)buf->b_u_line_colnr, 4);