|
Karsten Hopp |
87658d |
To: vim_dev@googlegroups.com
|
|
Karsten Hopp |
87658d |
Subject: Patch 7.3.088
|
|
Karsten Hopp |
87658d |
Fcc: outbox
|
|
Karsten Hopp |
87658d |
From: Bram Moolenaar <Bram@moolenaar.net>
|
|
Karsten Hopp |
87658d |
Mime-Version: 1.0
|
|
Karsten Hopp |
87658d |
Content-Type: text/plain; charset=UTF-8
|
|
Karsten Hopp |
87658d |
Content-Transfer-Encoding: 8bit
|
|
Karsten Hopp |
87658d |
------------
|
|
Karsten Hopp |
87658d |
|
|
Karsten Hopp |
87658d |
Patch 7.3.088
|
|
Karsten Hopp |
87658d |
Problem: Ruby can't load Gems sometimes, may cause a crash.
|
|
Karsten Hopp |
87658d |
Solution: Undefine off_t. Use ruby_process_options(). (Yasuhiro Matsumoto)
|
|
Karsten Hopp |
87658d |
Files: src/if_ruby.c
|
|
Karsten Hopp |
87658d |
|
|
Karsten Hopp |
87658d |
|
|
Karsten Hopp |
87658d |
*** ../vim-7.3.087/src/if_ruby.c 2010-12-08 13:11:15.000000000 +0100
|
|
Karsten Hopp |
87658d |
--- src/if_ruby.c 2010-12-24 12:18:31.000000000 +0100
|
|
Karsten Hopp |
87658d |
***************
|
|
Karsten Hopp |
87658d |
*** 90,95 ****
|
|
Karsten Hopp |
87658d |
--- 90,96 ----
|
|
Karsten Hopp |
87658d |
# include <ruby/encoding.h>
|
|
Karsten Hopp |
87658d |
#endif
|
|
Karsten Hopp |
87658d |
|
|
Karsten Hopp |
87658d |
+ #undef off_t /* ruby defines off_t as _int64, Mingw uses long */
|
|
Karsten Hopp |
87658d |
#undef EXTERN
|
|
Karsten Hopp |
87658d |
#undef _
|
|
Karsten Hopp |
87658d |
|
|
Karsten Hopp |
87658d |
***************
|
|
Karsten Hopp |
87658d |
*** 229,238 ****
|
|
Karsten Hopp |
87658d |
# define rb_enc_find_index dll_rb_enc_find_index
|
|
Karsten Hopp |
87658d |
# define rb_enc_find dll_rb_enc_find
|
|
Karsten Hopp |
87658d |
# define rb_enc_str_new dll_rb_enc_str_new
|
|
Karsten Hopp |
87658d |
- # define rb_intern2 dll_rb_intern2
|
|
Karsten Hopp |
87658d |
- # define rb_const_remove dll_rb_const_remove
|
|
Karsten Hopp |
87658d |
# define rb_sprintf dll_rb_sprintf
|
|
Karsten Hopp |
87658d |
# define ruby_init_stack dll_ruby_init_stack
|
|
Karsten Hopp |
87658d |
#endif
|
|
Karsten Hopp |
87658d |
|
|
Karsten Hopp |
87658d |
/*
|
|
Karsten Hopp |
87658d |
--- 230,239 ----
|
|
Karsten Hopp |
87658d |
# define rb_enc_find_index dll_rb_enc_find_index
|
|
Karsten Hopp |
87658d |
# define rb_enc_find dll_rb_enc_find
|
|
Karsten Hopp |
87658d |
# define rb_enc_str_new dll_rb_enc_str_new
|
|
Karsten Hopp |
87658d |
# define rb_sprintf dll_rb_sprintf
|
|
Karsten Hopp |
87658d |
+ # define rb_require dll_rb_require
|
|
Karsten Hopp |
87658d |
# define ruby_init_stack dll_ruby_init_stack
|
|
Karsten Hopp |
87658d |
+ # define ruby_process_options dll_ruby_process_options
|
|
Karsten Hopp |
87658d |
#endif
|
|
Karsten Hopp |
87658d |
|
|
Karsten Hopp |
87658d |
/*
|
|
Karsten Hopp |
87658d |
***************
|
|
Karsten Hopp |
87658d |
*** 319,329 ****
|
|
Karsten Hopp |
87658d |
static int (*dll_rb_enc_find_index) (const char*);
|
|
Karsten Hopp |
87658d |
static rb_encoding* (*dll_rb_enc_find) (const char*);
|
|
Karsten Hopp |
87658d |
static VALUE (*dll_rb_enc_str_new) (const char*, long, rb_encoding*);
|
|
Karsten Hopp |
87658d |
- static ID (*dll_rb_intern2) (const char*, long);
|
|
Karsten Hopp |
87658d |
- static void (*dll_Init_prelude) (void);
|
|
Karsten Hopp |
87658d |
- static VALUE (*dll_rb_const_remove) (VALUE, ID);
|
|
Karsten Hopp |
87658d |
static VALUE (*dll_rb_sprintf) (const char*, ...);
|
|
Karsten Hopp |
87658d |
static void (*ruby_init_stack)(VALUE*);
|
|
Karsten Hopp |
87658d |
#endif
|
|
Karsten Hopp |
87658d |
|
|
Karsten Hopp |
87658d |
#ifdef RUBY19_OR_LATER
|
|
Karsten Hopp |
87658d |
--- 320,329 ----
|
|
Karsten Hopp |
87658d |
static int (*dll_rb_enc_find_index) (const char*);
|
|
Karsten Hopp |
87658d |
static rb_encoding* (*dll_rb_enc_find) (const char*);
|
|
Karsten Hopp |
87658d |
static VALUE (*dll_rb_enc_str_new) (const char*, long, rb_encoding*);
|
|
Karsten Hopp |
87658d |
static VALUE (*dll_rb_sprintf) (const char*, ...);
|
|
Karsten Hopp |
87658d |
+ static VALUE (*dll_rb_require) (const char*);
|
|
Karsten Hopp |
87658d |
static void (*ruby_init_stack)(VALUE*);
|
|
Karsten Hopp |
87658d |
+ static void* (*ruby_process_options)(int, char**);
|
|
Karsten Hopp |
87658d |
#endif
|
|
Karsten Hopp |
87658d |
|
|
Karsten Hopp |
87658d |
#ifdef RUBY19_OR_LATER
|
|
Karsten Hopp |
87658d |
***************
|
|
Karsten Hopp |
87658d |
*** 430,439 ****
|
|
Karsten Hopp |
87658d |
{"rb_enc_find_index", (RUBY_PROC*)&dll_rb_enc_find_index},
|
|
Karsten Hopp |
87658d |
{"rb_enc_find", (RUBY_PROC*)&dll_rb_enc_find},
|
|
Karsten Hopp |
87658d |
{"rb_enc_str_new", (RUBY_PROC*)&dll_rb_enc_str_new},
|
|
Karsten Hopp |
87658d |
- {"rb_intern2", (RUBY_PROC*)&dll_rb_intern2},
|
|
Karsten Hopp |
87658d |
- {"rb_const_remove", (RUBY_PROC*)&dll_rb_const_remove},
|
|
Karsten Hopp |
87658d |
{"rb_sprintf", (RUBY_PROC*)&dll_rb_sprintf},
|
|
Karsten Hopp |
87658d |
{"ruby_init_stack", (RUBY_PROC*)&dll_ruby_init_stack},
|
|
Karsten Hopp |
87658d |
#endif
|
|
Karsten Hopp |
87658d |
{"", NULL},
|
|
Karsten Hopp |
87658d |
};
|
|
Karsten Hopp |
87658d |
--- 430,439 ----
|
|
Karsten Hopp |
87658d |
{"rb_enc_find_index", (RUBY_PROC*)&dll_rb_enc_find_index},
|
|
Karsten Hopp |
87658d |
{"rb_enc_find", (RUBY_PROC*)&dll_rb_enc_find},
|
|
Karsten Hopp |
87658d |
{"rb_enc_str_new", (RUBY_PROC*)&dll_rb_enc_str_new},
|
|
Karsten Hopp |
87658d |
{"rb_sprintf", (RUBY_PROC*)&dll_rb_sprintf},
|
|
Karsten Hopp |
87658d |
+ {"rb_require", (RUBY_PROC*)&dll_rb_require},
|
|
Karsten Hopp |
87658d |
{"ruby_init_stack", (RUBY_PROC*)&dll_ruby_init_stack},
|
|
Karsten Hopp |
87658d |
+ {"ruby_process_options", (RUBY_PROC*)&dll_ruby_process_options},
|
|
Karsten Hopp |
87658d |
#endif
|
|
Karsten Hopp |
87658d |
{"", NULL},
|
|
Karsten Hopp |
87658d |
};
|
|
Karsten Hopp |
87658d |
***************
|
|
Karsten Hopp |
87658d |
*** 663,680 ****
|
|
Karsten Hopp |
87658d |
ruby_init();
|
|
Karsten Hopp |
87658d |
}
|
|
Karsten Hopp |
87658d |
#ifdef RUBY19_OR_LATER
|
|
Karsten Hopp |
87658d |
ruby_script("vim-ruby");
|
|
Karsten Hopp |
87658d |
! #endif
|
|
Karsten Hopp |
87658d |
ruby_init_loadpath();
|
|
Karsten Hopp |
87658d |
- ruby_io_init();
|
|
Karsten Hopp |
87658d |
- #ifdef RUBY19_OR_LATER
|
|
Karsten Hopp |
87658d |
- rb_enc_find_index("encdb");
|
|
Karsten Hopp |
87658d |
-
|
|
Karsten Hopp |
87658d |
- /* This avoids the error "Encoding::ConverterNotFoundError: code
|
|
Karsten Hopp |
87658d |
- * converter not found (UTF-16LE to ASCII-8BIT)". */
|
|
Karsten Hopp |
87658d |
- rb_define_module("Gem");
|
|
Karsten Hopp |
87658d |
- rb_const_remove(rb_cObject, rb_intern2("TMP_RUBY_PREFIX", 15));
|
|
Karsten Hopp |
87658d |
#endif
|
|
Karsten Hopp |
87658d |
ruby_vim_init();
|
|
Karsten Hopp |
87658d |
ruby_initialized = 1;
|
|
Karsten Hopp |
87658d |
#ifdef DYNAMIC_RUBY
|
|
Karsten Hopp |
87658d |
--- 663,678 ----
|
|
Karsten Hopp |
87658d |
ruby_init();
|
|
Karsten Hopp |
87658d |
}
|
|
Karsten Hopp |
87658d |
#ifdef RUBY19_OR_LATER
|
|
Karsten Hopp |
87658d |
+ {
|
|
Karsten Hopp |
87658d |
+ int dummy_argc = 2;
|
|
Karsten Hopp |
87658d |
+ char *dummy_argv[] = {"vim-ruby", "-e0"};
|
|
Karsten Hopp |
87658d |
+ ruby_process_options(dummy_argc, dummy_argv);
|
|
Karsten Hopp |
87658d |
+ }
|
|
Karsten Hopp |
87658d |
ruby_script("vim-ruby");
|
|
Karsten Hopp |
87658d |
! #else
|
|
Karsten Hopp |
87658d |
ruby_init_loadpath();
|
|
Karsten Hopp |
87658d |
#endif
|
|
Karsten Hopp |
87658d |
+ ruby_io_init();
|
|
Karsten Hopp |
87658d |
ruby_vim_init();
|
|
Karsten Hopp |
87658d |
ruby_initialized = 1;
|
|
Karsten Hopp |
87658d |
#ifdef DYNAMIC_RUBY
|
|
Karsten Hopp |
87658d |
*** ../vim-7.3.087/src/version.c 2010-12-17 20:23:56.000000000 +0100
|
|
Karsten Hopp |
87658d |
--- src/version.c 2010-12-24 13:38:51.000000000 +0100
|
|
Karsten Hopp |
87658d |
***************
|
|
Karsten Hopp |
87658d |
*** 716,717 ****
|
|
Karsten Hopp |
87658d |
--- 716,719 ----
|
|
Karsten Hopp |
87658d |
{ /* Add new patch number below this line */
|
|
Karsten Hopp |
87658d |
+ /**/
|
|
Karsten Hopp |
87658d |
+ 88,
|
|
Karsten Hopp |
87658d |
/**/
|
|
Karsten Hopp |
87658d |
|
|
Karsten Hopp |
87658d |
--
|
|
Karsten Hopp |
87658d |
It is hard to understand how a cemetery raised its burial
|
|
Karsten Hopp |
87658d |
cost and blamed it on the cost of living.
|
|
Karsten Hopp |
87658d |
|
|
Karsten Hopp |
87658d |
/// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\
|
|
Karsten Hopp |
87658d |
/// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\
|
|
Karsten Hopp |
87658d |
\\\ an exciting new programming language -- http://www.Zimbu.org ///
|
|
Karsten Hopp |
87658d |
\\\ help me help AIDS victims -- http://ICCF-Holland.org ///
|