ready for release
git-svn-id: svn://127.0.0.1/Perl/File::Ownership::Unix/trunk@493 0c1c3402-1be1-de11-8092-0022686faf23
This commit is contained in:
parent
1fbe6db2f5
commit
1f3ff1ea2c
|
@ -1,4 +1,4 @@
|
|||
Revision history for File-Ownership-Unix
|
||||
|
||||
0.0.0 2011-08-14/06:30
|
||||
0.0.0 2011-08-14/06:50
|
||||
-Initial release.
|
||||
|
|
|
@ -63,24 +63,24 @@ sub new{
|
|||
};
|
||||
bless $self;
|
||||
|
||||
if(!defined($uid)){
|
||||
if(defined($uid)){
|
||||
$self->{uid}=$uid;
|
||||
}
|
||||
if(!defined($gid)){
|
||||
if(defined($gid)){
|
||||
$self->{gid}=$gid;
|
||||
}
|
||||
|
||||
if( $uid =~ /[0123456789]*/ ){
|
||||
if( $self->{gid} !~ /[0123456789]*/ ){
|
||||
$self->{perror}=1;
|
||||
$self->{error}=1;
|
||||
$self->{errorString}='"'.$uid.'" is not a valid value for';
|
||||
$self->{errorString}='"'.$self->{gid}.'" is not a valid value for GID';
|
||||
return $self;
|
||||
}
|
||||
|
||||
if( $gid =~ /[0123456789]*/ ){
|
||||
if( $self->{uid} !~ /[0123456789]*/ ){
|
||||
$self->{perror}=1;
|
||||
$self->{error}=1;
|
||||
$self->{errorString}='"'.$gid.'" is not a valid value for';
|
||||
$self->{errorString}='"'.$self->{uid}.'" is not a valid value for the UID';
|
||||
return $self;
|
||||
}
|
||||
|
||||
|
@ -186,9 +186,9 @@ sub setGID{
|
|||
return undef;
|
||||
}
|
||||
|
||||
if( $gid =~ /[0123456789]*/ ){
|
||||
if( $gid !~ /[0123456789]*/ ){
|
||||
$self->{error}=1;
|
||||
$self->{errorString}='"'.$gid.'" is not a valid value for';
|
||||
$self->{errorString}='"'.$gid.'" is not a valid value for GID';
|
||||
return $self;
|
||||
}
|
||||
|
||||
|
@ -217,9 +217,9 @@ sub setUID{
|
|||
return undef;
|
||||
}
|
||||
|
||||
if( $uid =~ /[0123456789]*/ ){
|
||||
if( $uid !~ /[0123456789]*/ ){
|
||||
$self->{error}=1;
|
||||
$self->{errorString}='"'.$uid.'" is not a valid value for';
|
||||
$self->{errorString}='"'.$uid.'" is not a valid value for UID';
|
||||
return $self;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue