mediamosa/mediamosa — pull request #74 by wsldankers (2013-06-13 13:02:50+00:00)
Title: Clear messages session variable after each ReST call

Drupal adds PHP error messages to the session variable "messages".
This variable is displayed and emptied when normal HTML pages are
displayed. However, ReST calls do not display these messages, and
the errors will keep accumulating. After enough ReST calls, the
message variable becomes large enough (>24MB) for the mysql client to
abort.

This patch clears the messages variable after each ReST call so the
variable doesn't keep growing infinitely.