removed unused functionality to load a subset of lines from a file in

Smarty::_read_file()

additionally removed a warning that is emitted since php-4.3.5 when
fread() is called on an empty file (with filesize()==0). thanks to
Andreas Streichardt who pointed this out.
This commit is contained in:
messju
2004-04-12 12:38:36 +00:00
parent 0af74476bc
commit 91549d3dba
3 changed files with 8 additions and 31 deletions

View File

@@ -240,7 +240,7 @@ class Config_File {
return false;
}
$contents = fread($fp, filesize($config_file));
$contents = ($size = filesize($config_file)) ? fread($fp, $size) : '';
fclose($fp);
$this->_config_data[$config_file] = $this->parse_contents($contents);