On the 6--1 dev branch (CVS)

Warning: Call-time pass-by-reference has been deprecated; ...  in /Library/WebServer/Documents/drupal6/sites/all/modules/modified/node_import/node_import.admin.inc on line 592
notice: Use of undefined constant NODE_IMPORT_MINIMUM_DRUPAL - assumed 'NODE_IMPORT_MINIMUM_DRUPAL' in /Library/WebServer/Documents/drupal6/sites/all/modules/modified/node_import/node_import.install on line 214.

Trivial stuff, trivial fix. Patch attached (quicker to do it by hand)

Comments

dman’s picture

StatusFileSize
new1.5 KB

Quite a few more. I've got PHP strict on. It's a pain, but follows best-practice, and helps debugging and testing.
notice: Undefined variable: path in /Library/WebServer/Documents/drupal6/sites/all/modules/modified/node_import/node_import.inc on line 1388.

    * notice: Undefined index: other record separator in /Library/WebServer/Documents/drupal6/sites/all/modules/modified/node_import/node_import.admin.inc on line 295.
    * notice: Undefined index: other field separator in /Library/WebServer/Documents/drupal6/sites/all/modules/modified/node_import/node_import.admin.inc on line 295.
    * notice: Undefined index: other text delimiter in /Library/WebServer/Documents/drupal6/sites/all/modules/modified/node_import/node_import.admin.inc on line 295.
    * notice: Undefined index: other escape character in /Library/WebServer/Documents/drupal6/sites/all/modules/modified/node_import/node_import.admin.inc on line 295.

um, etc etc. There's about 2 doz undeclared variables I've encountered at stages in the import. Probably a few left relating to features I've not yet used.
all just adding isset() where needed.

Robrecht Jacques’s picture

Status: Needs review » Needs work

The second patch is the same as the first.

I'd like to fix E_STRICT errors, but I have problems enabling this. Is adding

error_reporting(E_ALL | E_STRICT);

in sites/default/settings.php enough? It seems not. Can you tell me how to enable E_STRICT?

Thanks.

First patch committed.

dman’s picture

Sorry, that replacement probably replaced the previous one with the same name (I thought drupal upload was going to add a .0 to it or something) .. No, actually seems I re-uploaded the same one. My bad. (different systems listed my files in a different order) Here's the latest -03 . I guess it may start to conflict with the previous, so... ?

I do dev on a CVS checkout of Drupal core - which has strict on by default.
Non-dev Drupal I think does its own error_reporting override. Not sure of the best way to enable it yourself (without tweaking core) if doing it in settings.php is not enough.

Check your 'system error reporting settings' in the admin settings - you may have to enable it to see it on screen.

Robrecht Jacques’s picture

Status: Needs work » Fixed

Committed to CVS. I have installed Drupal 6.x-dev instead of Drupal 6.9 and will now see PHP5 strict warnings as well. But if you find some more, keep them coming. Thanks!

Status: Fixed » Closed (fixed)

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