WordPress.org

Make WordPress Core

Opened 8 years ago

Closed 6 years ago

#3014 closed defect (bug) (wontfix)

why use the @?

Reported by: Denis-de-Bernardy Owned by:
Milestone: Priority: normal
Severity: normal Version: 2.0.4
Component: Administration Keywords: needs-patch dev-feedback
Focuses: Cc:

Description (last modified by markjaquith)

Pinning down a bug on a customer server lead me to removing an '@':

Warning: dir() has been disabled for security reasons (...)

The pesky line in question was:

$themes_dir = @ dir($theme_root);

But there's plenty of other calls to:

@ dir(...)

Why in the bloody hell would anyone want WordPress to silence this kind of error? It should spit something along the lines of "Your host sucks, change it now."

Change History (10)

comment:1 markjaquith8 years ago

  • Description modified (diff)
  • Keywords needs-patch added
  • Milestone set to 2.1
  • Owner changed from anonymous to markjaquith
  • Status changed from new to assigned

I agree. And I'll bet Podz agrees too. When we hide the sins of poorly configured servers, we make their shortcomings into WordPress shortcomings in the mind of the people using WordPress, and we create a support burden for something that isn't even our problem.

comment:2 Nazgul8 years ago

  • Keywords dev-feedback added
  • Severity changed from major to normal

I disagree with just throwing the errors, because users will then blame WordPress for throwing those errors, generating just as much of a support burden.

Maybe it's an idea to include some kind of test during the initialization/install process. (Check if dir() is allowed, etc..)

comment:3 matt7 years ago

  • Milestone changed from 2.1 to 2.2

comment:4 m0n5t3r7 years ago

+1 for making the checks before installing

comment:5 foolswisdom7 years ago

  • Milestone changed from 2.2 to 2.3

comment:6 rob1n7 years ago

  • Owner changed from markjaquith to rob1n
  • Status changed from assigned to new

comment:7 markjaquith7 years ago

  • Milestone changed from 2.3 to 2.4 (next)

comment:8 westi7 years ago

Pre-flight checks in general are a good idea see #5235

comment:9 rob1n6 years ago

  • Owner rob1n deleted

We might want to close in deference to #5235, since that would fix this and a host of other pre-flight problems.

comment:10 Nazgul6 years ago

  • Milestone 2.5 deleted
  • Resolution set to wontfix
  • Status changed from new to closed

This ticket has had no real activity for over some time and has been partially superseeded by #5235, so closing as invalid for now.

Feel free to re-open if you have additional patches/information/suggestions/...

Note: See TracTickets for help on using tickets.