aboutsummaryrefslogtreecommitdiffstats
path: root/shells
diff options
context:
space:
mode:
authoramdmi3 <amdmi3@FreeBSD.org>2010-01-14 03:30:19 +0800
committeramdmi3 <amdmi3@FreeBSD.org>2010-01-14 03:30:19 +0800
commite7474cebfe1452ec53aec61f30531495cfd23e4b (patch)
tree97a23e3bcc49f838ddf779cde2f125b3fef67b79 /shells
parent35b3fa49bbc09d1fb3f64f5ff130ec6ddcfb2a69 (diff)
downloadfreebsd-ports-gnome-e7474cebfe1452ec53aec61f30531495cfd23e4b.tar.gz
freebsd-ports-gnome-e7474cebfe1452ec53aec61f30531495cfd23e4b.tar.zst
freebsd-ports-gnome-e7474cebfe1452ec53aec61f30531495cfd23e4b.zip
- Fix potential division by zero bug
PR: 142785 Submitted by: Rob Farmer <rfarmer@predatorlabs.net> (maintainer)
Diffstat (limited to 'shells')
-rw-r--r--shells/fish/Makefile1
-rw-r--r--shells/fish/files/patch-util.c14
2 files changed, 15 insertions, 0 deletions
diff --git a/shells/fish/Makefile b/shells/fish/Makefile
index 327c3db1e8c2..2f5e1671722f 100644
--- a/shells/fish/Makefile
+++ b/shells/fish/Makefile
@@ -7,6 +7,7 @@
PORTNAME= fish
PORTVERSION= 1.23.1
+PORTREVISION= 1
CATEGORIES= shells
MASTER_SITES= SF
diff --git a/shells/fish/files/patch-util.c b/shells/fish/files/patch-util.c
new file mode 100644
index 000000000000..8e7150165042
--- /dev/null
+++ b/shells/fish/files/patch-util.c
@@ -0,0 +1,14 @@
+
+--- util.c.orig 2010-01-13 06:44:46.000000000 -0800
++++ util.c 2010-01-13 06:46:39.000000000 -0800
+@@ -320,7 +320,7 @@
+ {
+ int pos;
+
+- if( (float)(h->count+1)/h->size > 0.75f )
++ if( (float)(h->count+1) > 0.75f * h->size )
+ {
+ if( !hash_realloc( h, (h->size+1) * 2 -1 ) )
+ {
+
+