+44 0330 223 3428
Call Us
+44 0330 223 3428

WPTavern: WordPress 4.9.8 Will Significantly Reduce Memory Leak

WPTavern: WordPress 4.9.8 Will Significantly Reduce Memory Leak

WordPress 4.9.8 Beta two recently shipped and although much of the focus will be on the “Try Gutenberg” call-out, there’s a patch included that addresses a memory leak that was quite a problem for some users.

When WordPress 4.9.7 shipped, the WordPress.org support forums saw an increase in reports of memory exhausted errors due to the wp_is_stream function.

The bug is actually in PHP and is related to the stream-get-wrappers function. WordPress 4.9.7 increased the number of times it calls the wp_is_stream() function generating the error more often.

After thoughtful conversations within the trac ticket, a patch was created that after further testing, was committed to core. According to Gary Pendergast, the patch does the following.

Bailing if the path isn’t a stream. This isn’t perfect: it’s still possible to trigger the PHP bug, but it does significantly reduce the chances of the bug being encountered. For many WordPress sites (those that don’t have plugins that use streams), it reduces the chance to zero.

If you encountered memory exhaustion errors after installing or upgrading to WordPress 4.9.7, try WordPress 4.9.8 Beta 2 to see if it fixes the issue.

Aside from coming up with a solution, Trac ticket #44532 is a bit refreshing to see. In open source, tickets or issues can get bogged down with suggestions, hypothetical scenarios, and bike-shed commentary.

In this instance, the issue was identified and folks from the community along with core contributors worked together in a focused fashion to create a fix in time for the next point release. The ticket is a good example of what it’s like when open source is firing on all cylinders. 


WordPress 4.9.8 Beta two recently shipped and although much of the focus will be on the “Try Gutenberg” call-out, there’s a patch included that addresses a memory leak that was quite a problem for some users. When WordPress 4.9.7 shipped, the WordPress.org support forums saw an increase in reports of memory exhausted errors due to the wp_is_stream function. The bug is actually in PHP and is related to the stream-get-wrappers function. WordPress 4.9.7 increased the number of times it calls the wp_is_stream() function generating the error more often. After thoughtful conversations within the trac ticket, a patch was created that after…

Source: WordPress

Related Post
WPTavern: WordPress 5.0.2 to Bring Major Performance Improvements, Scheduled for December 19

WPTavern: WordPress 5.0.2 to Bring Major Performance Improvements, Scheduled for December 19 Processed with VSCOcam with c1 preset WordPress 5.0.1 was released yesterday as a security release with fixes for seven vulnerabilities that were privately disclosed. It includes a few breaks in backwards compatibility that plugin developers will want to review. WordPress 5.0.2 will be […]

Read more
WPTavern: WPWeekly Episode 341 – Recap of WordCamp US 2018

WPTavern: WPWeekly Episode 341 – Recap of WordCamp US 2018 In this episode, John James Jacoby and I recap WordCamp US 2018. We discuss what’s new in WordPress 5.0.1 and when users can expect to see 5.0.2. We also chat about the new path that WordPress is on and where it may lead. John shares […]

Read more
WPTavern: WordCamp US 2019 to be Held November 1-3 in St. Louis

WPTavern: WordCamp US 2019 to be Held November 1-3 in St. Louis photo credit: Wikimedia Commons Dates for WordCamp US 2019 were announced today, less than a week after wrapping up a successful camp in Nashville. Unlike all previous years held in December, next year’s event will take place November 1-3 in St. Louis, Missouri. […]

Read more