--- /dev/null
+--- ruby-mongrel-1.1.5/ext/http11/http11.c~ 2014-01-26 13:13:47.000000000 +0100
++++ ruby-mongrel-1.1.5/ext/http11/http11.c 2014-01-26 13:15:20.786156849 +0100
+@@ -44,7 +44,7 @@
+ #define DEF_MAX_LENGTH(N,length) const size_t MAX_##N##_LENGTH = length; const char *MAX_##N##_LENGTH_ERR = "HTTP element " # N " is longer than the " # length " allowed length."
+
+ /** Validates the max length of given input and throws an HttpParserError exception if over. */
+-#define VALIDATE_MAX_LENGTH(len, N) if(len > MAX_##N##_LENGTH) { rb_raise(eHttpParserError, MAX_##N##_LENGTH_ERR); }
++#define VALIDATE_MAX_LENGTH(len, N) if(len > MAX_##N##_LENGTH) { rb_raise("%s", eHttpParserError, MAX_##N##_LENGTH_ERR); }
+
+ /** Defines global strings in the init method. */
+ #define DEF_GLOBAL(N, val) global_##N = rb_obj_freeze(rb_str_new2(val)); rb_global_variable(&global_##N)
# Source0-md5: a37617eb48f0932cc32143b2d76c0d12
Patch0: %{name}-nogems.patch
Patch1: %{name}-ruby1.9.patch
+Patch2: format-security.patch
URL: http://mongrel.rubyforge.org/
BuildRequires: dos2unix
BuildRequires: rpmbuild(macros) >= 1.277
BuildRequires: ruby-devel
+BuildRequires: ruby-irb
BuildRequires: ruby-modules
%{?ruby_mod_ver_requires_eq}
BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
dos2unix examples/mongrel_simple_service.rb
%patch0 -p1
%patch1 -p1
+%patch2 -p1
find -name '*.rb' -print0 | xargs -0 %{__sed} -i -e 's,\r$,,'