From 9b0ac229bcfc91acabd35fc576055a94c1687c32 Mon Sep 17 00:00:00 2001 From: Bram Moolenaar Date: Wed, 1 Jun 2016 20:31:43 +0200 Subject: patch 7.4.1863 Problem: Compiler warnings on Win64. Solution: Adjust types, add type casts. (Ken Takata) --- src/if_perl.xs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'src/if_perl.xs') diff --git a/src/if_perl.xs b/src/if_perl.xs index aab7ade227..a4899945fe 100644 --- a/src/if_perl.xs +++ b/src/if_perl.xs @@ -1075,7 +1075,8 @@ perl_to_vim(SV *sv, typval_T *rettv) { size_t len = 0; char * str_from = SvPV(sv, len); - char_u *str_to = (char_u*)alloc(sizeof(char_u) * (len + 1)); + char_u *str_to = (char_u*)alloc( + (unsigned)(sizeof(char_u) * (len + 1))); if (str_to) { str_to[len] = '\0'; @@ -1370,13 +1371,13 @@ PerlIOVim_write(pTHX_ PerlIO *f, const void *vbuf, Size_t count) char_u *str; PerlIOVim * s = PerlIOSelf(f, PerlIOVim); - str = vim_strnsave((char_u *)vbuf, count); + str = vim_strnsave((char_u *)vbuf, (int)count); if (str == NULL) return 0; msg_split((char_u *)str, s->attr); vim_free(str); - return count; + return (SSize_t)count; } static PERLIO_FUNCS_DECL(PerlIO_Vim) = { -- cgit v1.2.3