diff options
author | Bram Moolenaar <Bram@vim.org> | 2019-02-23 14:23:03 +0100 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2019-02-23 14:23:03 +0100 |
commit | 0d13cce3453b2274c93c5015faa1993baaebace9 (patch) | |
tree | 5cf62aee4d8867db3bbba63795c3829aae1055f9 /src/if_ruby.c | |
parent | e4963c543ddcfc4845fa0d42893b6a4e1aa27c47 (diff) | |
download | vim-git-0d13cce3453b2274c93c5015faa1993baaebace9.tar.gz |
patch 8.1.0977: blob not tested with Rubyv8.1.0977
Problem: Blob not tested with Ruby.
Solution: Add more test coverage. fixes a crash. (Dominique Pelle,
closes #4036)
Diffstat (limited to 'src/if_ruby.c')
-rw-r--r-- | src/if_ruby.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/if_ruby.c b/src/if_ruby.c index d3ed78128..543ee8ac2 100644 --- a/src/if_ruby.c +++ b/src/if_ruby.c @@ -1267,7 +1267,7 @@ static VALUE vim_blob(VALUE self UNUSED, VALUE str) int i; for (i = 0; i < RSTRING_LEN(str); i++) { - sprintf(buf, "%02X", RSTRING_PTR(str)[i]); + sprintf(buf, "%02X", (unsigned char)(RSTRING_PTR(str)[i])); rb_str_concat(result, rb_str_new2(buf)); } return result; |