/[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 312 by dpavlin, Thu Aug 27 14:30:55 2009 UTC revision 313 by dpavlin, Thu Aug 27 18:59:12 2009 UTC
# Line 79  sub all_conf { Line 79  sub all_conf {
79  }  }
80  sub next_ip($) {  sub next_ip($) {
81          my $mac = shift;          my $mac = shift;
82            $mac = format::mac($mac);
83    
84          my $p = Net::Ping->new;          my $p = Net::Ping->new;
85    
# Line 102  sub next_ip($) { Line 103  sub next_ip($) {
103    
104  sub save_ip_mac {  sub save_ip_mac {
105          my ($ip,$mac) = @_;          my ($ip,$mac) = @_;
106            $mac = format::mac($mac);
107    
108          mkdir ip_path($ip) unless -e ip_path($ip);          mkdir ip_path($ip) unless -e ip_path($ip);
109    
# Line 113  sub save_ip_mac { Line 115  sub save_ip_mac {
115    
116  sub ip_from_mac($) {  sub ip_from_mac($) {
117          my $mac = shift;          my $mac = shift;
118            $mac = format::mac($mac);
         $mac = lc $mac;  
         $mac =~ s{:}{}g;  
119    
120          my $mac_path = mac_path $mac;          my $mac_path = mac_path $mac;
121          return unless -e $mac_path;          return unless -e $mac_path;

Legend:
Removed from v.312  
changed lines
  Added in v.313

  ViewVC Help
Powered by ViewVC 1.1.26