cvs: php-src /ext/gd/libgd gd.c
| From: | Pierre-Alain Joye | Date: | Sat, 14 Apr 2007 17:30:51 +0000 |
| Subject: | cvs: php-src /ext/gd/libgd gd.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-43882@lists.php.net to get a copy of this message | ||
pajoye Sat Apr 14 17:30:51 2007 UTC
Modified files:
/php-src/ext/gd/libgd gd.c
Log:
- libgd #74, gdImageFilledArc, huge CPU usage with large angles
http://cvs.php.net/viewvc.cgi/php-src/ext/gd/libgd/gd.c?r1=1.103&r2=1.104&diff_format=u
Index: php-src/ext/gd/libgd/gd.c
diff -u php-src/ext/gd/libgd/gd.c:1.103 php-src/ext/gd/libgd/gd.c:1.104
--- php-src/ext/gd/libgd/gd.c:1.103 Sat Mar 10 01:23:42 2007
+++ php-src/ext/gd/libgd/gd.c Sat Apr 14 17:30:51 2007
@@ -1643,6 +1643,14 @@
int lx = 0, ly = 0;
int fx = 0, fy = 0;
+ if (s > 360) {
+ s = s % 360;
+ }
+
+ if (e > 360) {
+ e = e % 360;
+ }
+
while (s<0) {
s += 360;
}