<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1,4 +1,5 @@
 == 0.7.1 Fancy Pants release
+ * Ruby 1.8.5 compatibility, closes #49 [Wincent Colaiuta]
  * Move all EventMachine stuff out of Server, you can now create a Thin Backend that
    does not depend on EventMachine.
  * Rename Connector to Backend. Extend Thin::Backends::Base to implement your own.</diff>
      <filename>CHANGELOG</filename>
    </modified>
    <modified>
      <diff>@@ -87,6 +87,8 @@ module Thin
       else
         Backends::TcpServer.new(host_or_socket_or_backend, port.to_i)
       end
+      
+      load_cgi_multipart_eof_fix
 
       @app            = app
       @backend.server = self
@@ -186,6 +188,20 @@ module Thin
         trap('QUIT') { stop }  unless Thin.win?
         trap('INT')  { stop! }
         trap('TERM') { stop! }
-      end      
+      end
+      
+      # Taken from Mongrel cgi_multipart_eof_fix
+      def load_cgi_multipart_eof_fix
+        version = RUBY_VERSION.split('.').map { |i| i.to_i }
+        
+        if version[0] &lt;= 1 &amp;&amp; version[1] &lt;= 8 &amp;&amp; version[2] &lt;= 5 &amp;&amp; RUBY_PLATFORM !~ /java/
+          begin
+            require 'cgi_multipart_eof_fix'
+          rescue LoadError
+            log &quot;!! Ruby 1.8.5 is not secure please install cgi_multipart_eof_fix:&quot;
+            log &quot;   gem install cgi_multipart_eof_fix&quot;
+          end
+        end
+      end
   end
 end
\ No newline at end of file</diff>
      <filename>lib/thin/server.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>3380e9a2bdafb94b75b766255e4cd00fb4eb0046</id>
    </parent>
  </parents>
  <author>
    <name>macournoyer</name>
    <email>macournoyer@gmail.com</email>
  </author>
  <url>http://github.com/macournoyer/thin/commit/4c30c781a26b14bd7038646a6c258f57cb91c1f3</url>
  <id>4c30c781a26b14bd7038646a6c258f57cb91c1f3</id>
  <committed-date>2008-03-02T11:32:21-08:00</committed-date>
  <authored-date>2008-03-02T11:32:21-08:00</authored-date>
  <message>Load cgi_multipart_eof_fix if Ruby 1.8.5, closes #49</message>
  <tree>8d363642dfc6baf12dd4273676e62c684b26c098</tree>
  <committer>
    <name>macournoyer</name>
    <email>macournoyer@gmail.com</email>
  </committer>
</commit>
