Ticket #73 (closed defect: fixed)
Semantical error in PhingFile::getParent()
| Reported by: | micha@… | Owned by: | mrook |
|---|---|---|---|
| Priority: | major | Milestone: | 2.3.0 |
| Component: | Version: | 2.2.0 | |
| Keywords: | Cc: |
Description
a semantical error in class PhingFile prevents method getParent() to return the parent of a directory or file if the parent is the root directory of the filesystem.
example:
$file = new PhingFile( "/tmp" ); $parent = $file->getParent(); // $parent is null instead of "/"
a patch that fixes this problem is attached to this ticket. the patch is created against current revision 147.
Attachments
Change History
Changed 5 years ago by micha@…
-
attachment
PhingFile.php-rev147.patch
added
comment:1 Changed 5 years ago by norman@…
Sorry micha, your patch is incorrect, isn't it?
You wrote
if (($this->prefixLength > 0) && (strlen($this->path) > $this->prefixLength))) {
...
}
but shouldn't it be
if (($this->prefixLength > 0) && (strlen($this->path) > $this->prefixLength)) {
...
}
or am I missunderstand something? (Please count the numbers of '(' and ')'.)
Yours
Norman
comment:2 Changed 5 years ago by micha@…
you're right - sorry, my fault. fixed a semantical error and added a syntax error...
patched patch will be attached ;)
comment:4 Changed 5 years ago by mrook
- Status changed from new to closed
- Resolution set to fixed
Fixed in r163.
comment:6 Changed 3 years ago by Frank
BOFH Excuse #208:
Your mail is being routed through Germany ... and they're censoring us. italia cialis http://www.compraviagraitalia.com/it/item/generic_cialis.html viagra prezzi http://compraviagraitalia.com/index.html
http://headachetreatment.net/index.html viagra generico sicuro http://www.compraviagraitalia.com/it/item/generic_viagra.html
http://relievepain.org/tramadol-news/index.php?entry=entry090118-104934

Patch for PhingFile against revision 147