- Timestamp:
- 06/25/12 18:38:25 (12 years ago)
- Location:
- bot/trunk
- Files:
-
- 2 added
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
bot/trunk/MANIFEST
r397 r439 10 10 sophie-tools.spec.in 11 11 t/Sophie-Bot.t 12 sysinit/sophie-bot -
bot/trunk/bin/sophie-bot
r433 r439 43 43 $runas ||= $config{runas}; 44 44 $pidfile ||= $config{pidfile}; 45 $type ||= $config{type}; 45 46 } 46 47 … … 88 89 } 89 90 90 if ($runas) {91 my ($login,$pass,$uid,$gid) = $runas =~ /^\d/92 ? getpwuid($runas)93 : getpwnam($runas);94 95 $> = $uid; $) = $gid;96 if ($> ne $uid) {97 die "Cannot change to user $runas\n";98 }99 }100 101 91 if ($daemon) { 102 103 92 my $pid = fork(); 104 93 … … 121 110 } 122 111 112 if ($runas) { 113 my ($login,$pass,$uid,$gid) = $runas =~ /^\d/ 114 ? getpwuid($runas) 115 : getpwnam($runas); 116 117 $> = $uid; $) = $gid; 118 if ($> ne $uid) { 119 die "Cannot change to user $runas\n"; 120 } 121 } 122 123 123 $sc->run; 124 124 -
bot/trunk/lib/Sophie/Bot.pm
r433 r439 8 8 $RPC::XML::FORCE_STRING_ENCODING = 1; 9 9 10 our $VERSION = '0.0 1';10 our $VERSION = '0.02'; 11 11 12 12 sub new { -
bot/trunk/lib/Sophie/Bot/IRC.pm
r433 r439 62 62 $heap->{nopong} ||= 0; 63 63 if ($heap->{nopong} >= NO_PONG_TOUT) { 64 $ heap->{irc}->yield( 'connect', { } );64 $_[KERNEL]->stop; 65 65 return; 66 66 } … … 90 90 91 91 $_[KERNEL]->stop; 92 #die "Nick already in use\n";93 92 } 94 93 -
bot/trunk/sophie-bot.spec.in
r405 r439 38 38 %makeinstall_std 39 39 40 mkdir -p %buildroot%_sysconfdir/init.d 41 install -m755 sysinit/sophie-bot %buildroot%_sysconfdir/init.d/sophie-bot 42 40 43 %clean 41 44 rm -rf %buildroot … … 44 47 %defattr(-,root,root) 45 48 %doc Changes README 49 %_sysconfdir/init.d/sophie-bot 46 50 %_bindir/* 47 51 %{_mandir}/*/*
Note: See TracChangeset
for help on using the changeset viewer.