I encountered the error in album.php too. Curiously simply doing
parse_str('gid[]=18');
print_r($gid);
did not cause a problem, but doing print_r($gid)
in xdebug causes the segfault.
Ubuntu 16.04 LTS does not provide PHP 7.1 by default, so I want to fix the problem in the nextgen plugin. The above use of parse_str
is highly discouraged anyway (though I think this instance is not a security issue).
Could you please apply the following patch, so the next update wont overwrite my changes:
--- WordPress/wp-content/plugins/nextgen-gallery/products/photocrati_nextgen/modules/ngglegacy/admin/album.php 2017-05-04 09:37:02.000000000 +0100
+++ Plugins/nextgen-gallery/products/photocrati_nextgen/modules/ngglegacy/admin/album.php 2017-06-08 18:58:14.000000000 +0100
@@ -191,10 +191,10 @@
$album = $this->_get_album($this->currentID);
// Get the list of galleries/sub-albums to be added to this album
- parse_str($_REQUEST['sortorder']);
+ parse_str($_REQUEST['sortorder'], $sortorder);
// Set the new sortorder
- $album->sortorder = $gid;
+ $album->sortorder = $sortorder['gid'];
// Ensure that a preview pic has been sent
$this->_set_album_preview_pic($album);
Thank you
-
This reply was modified 7 years, 5 months ago by bodo.
-
This reply was modified 7 years, 5 months ago by bodo.