/[pxelator]/lib/PXElator/client.pm
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /lib/PXElator/client.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 189 by dpavlin, Sun Aug 9 22:05:09 2009 UTC revision 190 by dpavlin, Mon Aug 10 00:07:38 2009 UTC
# Line 41  sub conf { Line 41  sub conf {
41  }  }
42    
43  sub mac {  sub mac {
44          my $ip = shift;          my ( $ip, $op ) = @_;
45            $op ||= 'html';
46          my $mac = client::conf( $ip, 'mac' );          my $mac = client::conf( $ip, 'mac' );
47          return '' unless $mac;          return '' unless $mac;
48          $mac =~ s{(..)}{$1:}g;          $mac =~ s{(..)}{$1:}g;
49          $mac =~ s{:$}{};          $mac =~ s{:$}{};
50          $mac = qq|<tt>$mac</tt>| if (caller(1))[3] =~ m{^httpd};          $mac = qq|<tt>$mac</tt>| if (caller(1))[3] =~ m{^httpd} && $op ne 'clean';
51          return uc($mac);          return uc($mac);
52  }  }
53    

Legend:
Removed from v.189  
changed lines
  Added in v.190

  ViewVC Help
Powered by ViewVC 1.1.26