summaryrefslogtreecommitdiff
path: root/ruby.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1999-07-15 07:59:59 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1999-07-15 07:59:59 +0000
commit86307f52ee1b3c5aa76e2fd6ee118e681dd76905 (patch)
tree4f5675ce901200d4245c6697d4e8d1c224949174 /ruby.c
parente12510c502a3c8a81aeda66d1867eb1e760ce533 (diff)
990715
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_3@497 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ruby.c')
-rw-r--r--ruby.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/ruby.c b/ruby.c
index 004dc1fe90..5f53da2a18 100644
--- a/ruby.c
+++ b/ruby.c
@@ -634,7 +634,7 @@ load_file(fname, script)
char *path;
char *pend = RSTRING(line)->ptr + RSTRING(line)->len;
- p = RSTRING(line)->ptr + 2; /* skip `#!' */
+ p = RSTRING(line)->ptr + 1; /* skip `#!' */
if (pend[-1] == '\n') pend--; /* chomp line */
if (pend[-1] == '\r') pend--;
*pend = '\0';
@@ -884,6 +884,10 @@ ruby_prog_init()
addpath(RUBY_SITE_THIN_ARCHLIB);
#endif
+#ifdef RUBY_SEARCH_PATH
+ addpath(RUBY_SEARCH_PATH);
+#endif
+
if (rb_safe_level() == 0) {
addpath(getenv("RUBYLIB"));
}