1 |
wellsi |
1.1 |
diff -ruN e-smith-samba-2.4.0.old/root/etc/e-smith/db/accounts/migrate/40MachineUid e-smith-samba-2.4.0/root/etc/e-smith/db/accounts/migrate/40MachineUid |
2 |
|
|
--- e-smith-samba-2.4.0.old/root/etc/e-smith/db/accounts/migrate/40MachineUid 2013-01-31 13:31:40.000000000 -0800 |
3 |
|
|
+++ e-smith-samba-2.4.0/root/etc/e-smith/db/accounts/migrate/40MachineUid 1969-12-31 16:00:00.000000000 -0800 |
4 |
|
|
@@ -1,14 +0,0 @@ |
5 |
|
|
-{ |
6 |
|
|
- foreach my $machine ($DB->get_all_by_prop(type => 'machine')) |
7 |
|
|
- { |
8 |
|
|
- next if defined $machine->prop('Uid'); |
9 |
|
|
- |
10 |
|
|
- my ($uid, $gid) = (getpwnam($machine->key))[2,3]; |
11 |
|
|
- |
12 |
|
|
- next unless defined $uid; |
13 |
|
|
- $machine->set_prop('Uid', $uid); |
14 |
|
|
- |
15 |
|
|
- next unless $gid != $uid; |
16 |
|
|
- $machine->set_prop('Gid', $gid); |
17 |
|
|
- } |
18 |
|
|
-} |