Patching 6.0.4 -> 6.0.5 makes Dolibarr not working

We use 6.0.4 in our company. We had a lot of issues last time we did a major upgrade so we’re not interested in upgrading to 7 right now.

However, I found out about the SQL injection bug, so I wanted to upgrade to 6.0.5. I git cloned the full repo, run “git diff 6.0.4…6.0.5 > db.patch” to get the diff.

I backed up the whole 6.0.4-tree and then applied the patch, but only get “There is an error while processing this request.” in my web browser. Checking the Apache logs, I see this:

2018-04-11T12:14:58+02:00 InnZ_NAS [Wed Apr 11 12:14:58 2018] [error] [client 90.229.254.197] (104)Connection reset by peer: FastCGI: comm with server "/default-php-27329e2f-4c68-415a-8ef8-a7c04e68f987" aborted: read failed 2018-04-11T12:14:58+02:00 InnZ_NAS [Wed Apr 11 12:14:58 2018] [error] [client 90.229.254.197] FastCGI: incomplete headers (0 bytes) received from server "/default-php-27329e2f-4c68-415a-8ef8-a7c04e68f987" 2018-04-11T12:14:58+02:00 InnZ_NAS [Wed Apr 11 12:14:58 2018] [error] [client 90.229.254.197] File does not exist: /var/services/web/favicon.ico 2018-04-11T12:14:58+02:00 InnZ_NAS [Wed Apr 11 12:14:58 2018] [error] [client 90.229.254.197] File does not exist: /var/services/web/missing, referer: http://<censored>/dolibarr/htdocs/

Reverting back to 6.0.4, everything works fine.

So, what went wrong here?

Are the files accessible by the Web Server? UID & GID set correctly?