You get a warning when try to see any book type node:
strict warning: Only variables should be passed by reference in /usr/local/www/apache22/data/modules/book/book.module on line 559.
line 559 of book.module:
$data = array_shift(book_menu_subtree_data($prev));

Solution/Workaround:
Split line 559 of the book.module like this:

$pepito = book_menu_subtree_data($prev);
$data = array_shift($pepito);

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

joelpittet’s picture

Version: 6.26 » 6.x-dev
Issue summary: View changes
Status: Active » Needs review
Issue tags: +Quick fix
FileSize
757 bytes

Here's the patch as indicated in the issue summary.

DarrellDuane’s picture

Status: Needs review » Reviewed & tested by the community

I applied this patch and the error messages stopped. Please commit.

Status: Reviewed & tested by the community » Needs work

The last submitted patch, 1: 1707928-1-book-php5-strict.patch, failed testing.

Status: Needs work » Needs review

Status: Needs review » Needs work

The last submitted patch, 1: 1707928-1-book-php5-strict.patch, failed testing.

Polonium’s picture

FileSize
796 bytes

Please, look at my work.

joelpittet’s picture

@Polonium I've got a hard time trying to figure out if that is spam or not? It looks like you took the patch in #1 and added some persons name into it as a variable name and the patch is not a correct patch without the + or -.

Can you explain what you were trying to do in #6 that is different thand #1?

tadityar’s picture

@joelpittet hello! This issue had been RTBC-ed and also passed the test so what's the problem here?

dawehner’s picture

as said on irc #1 is fine, but the question is whether the problem also appears in D7?

tadityar’s picture

Status: Needs work » Reviewed & tested by the community

I tested the 7.x branch in simplytest.me, tried creating a book nodetype and its child, and when I tried to see it there are no PHP strict warning. The patch previously failed because of testbot issues and re-testing solved it.

The patch in #1 also solved the issue based on #2 so re-upping the RTBC :)

Status: Reviewed & tested by the community » Needs work

The last submitted patch, 6: 1707928-1-book-php5-strict.patch, failed testing.

tadityar’s picture

Status: Needs work » Reviewed & tested by the community

The wrong patch got tested.. sorry.

joelpittet’s picture

Thanks @tadityar and @DarrellDuane for testing it:)

RytoEX’s picture

I just ran into this today while testing Drupal 6 on PHP 5.4. If the patch from #1 fixes this and is RTBC, what's keeping this from moving to be Fixed?

dazweeja’s picture

Please commit this two-line patch. It solves the issue and is just good coding practice.

Status: Reviewed & tested by the community » Closed (outdated)

Automatically closed because Drupal 6 is no longer supported. If the issue verifiably applies to later versions, please reopen with details and update the version.

jstoller’s picture

Here's a working patch, in case anyone else needs it.

dsnopek’s picture

Project: Drupal core » Drupal 6 Long Term Support
Version: 6.x-dev »
Component: book.module » Code
Status: Closed (outdated) » Needs review

Moving to D6LTS project

dsnopek’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.