Remove warning for passing non-variable by reference.

PHP in strict mode does not allow an expression to be passed to a function
directly, instead an intermediate variable must be used. The code will
still run and behave as expected at the moment, but is not future-proof,
so I have changed it to use an intermediate variable to remove the warning
and to prevent possible problems with future versions of PHP.

For more information, see: https://groups.drupal.org/node/27214
Merge branch '7.x-1.x'