summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--bignum.c1
2 files changed, 6 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 2ed7a86..9130664 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+Sun May 25 23:48:21 2003 Nobuyoshi Nakada <nobu.nokada@softhome.net>
+
+ * bignum.c (rb_quad_pack): should negate negative bignum.
+ (ruby-bugs-ja:PR#474)
+
Sun May 25 03:27:25 2003 Minero Aoki <aamine@loveruby.net>
* lib/net/smtp.rb: support LOGIN authentication, based on
diff --git a/bignum.c b/bignum.c
index 01c8824..5992662 100644
--- a/bignum.c
+++ b/bignum.c
@@ -206,6 +206,7 @@ rb_quad_pack(buf, val)
q = BIGUP(q);
q += ds[len];
}
+ if (!RBIGNUM(val)->sign) q = -q;
}
memcpy(buf, (char*)&q, SIZEOF_LONG_LONG);
}