summaryrefslogtreecommitdiff
path: root/hash.c
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1998-05-25 04:58:02 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1998-05-25 04:58:02 +0000
commit45c61f40b23b14e97428206e1b813eb813526e6f (patch)
treebbffa6043ed1e8b6a501d23c3b4874ae3390ddd8 /hash.c
parent369fe1e8394b494c78d56aedfe6b0b809d7d1c10 (diff)
remove unused variables
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/v1_1r@222 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'hash.c')
-rw-r--r--hash.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/hash.c b/hash.c
index 4a97c62..bf77840 100644
--- a/hash.c
+++ b/hash.c
@@ -164,6 +164,7 @@ hash_foreach_ensure(hash)
FL_UNSET(hash, HASH_DELETED);
}
}
+ return 0;
}
static int
@@ -193,13 +194,14 @@ hash_s_new(argc, argv, klass)
NEWOBJ(hash, struct RHash);
OBJSETUP(hash, klass, T_HASH);
+ hash->iter_lev = 0;
+ hash->status = 0;
+ hash->tbl = 0; /* avoid GC crashing */
+
rb_scan_args(argc, argv, "01", &sz);
if (NIL_P(sz)) size = 0;
else size = NUM2INT(sz);
- hash->iter_lev = 0;
- hash->status = 0;
- hash->tbl = 0; /* avoid GC crashing */
hash->tbl = st_init_table_with_size(&objhash, size);
obj_call_init((VALUE)hash);
@@ -916,8 +918,6 @@ f_setenv(obj, name, value)
setenv(RSTRING(name)->ptr, RSTRING(value)->ptr, 1);
if (strcmp(RSTRING(name)->ptr, "PATH") == 0) {
- char *p, pend;
-
if (str_tainted(value)) {
/* already tainted, no check */
path_tainted = 1;