- if (!shmwrite($key,$str,$position,$size)) {
+ my $read = &shmRead($key);
+ $read =~ s/\0+//g;
+ if ($read eq "") {
+ $str = sprintf("%s:%d:%d: ", $param{ircNick}, $bot_pid, time());
+ } else {
+ $str = $read ."||". $str;
+ }
+
+ if (!shmwrite($key, $str, $position, $size)) {
+ &DEBUG("shmWrite($key, $str)");