From a864144205f693ae2ddefa9437d0f51104bb4821 Mon Sep 17 00:00:00 2001
From: Philip Reetz
Date: Tue, 11 Oct 2005 08:31:51 +0000
Subject: [PATCH] Speicherroutinen gepatcht: uid um einen Zufallswert ergaenzt,
damit Batchoperationen nicht fehlschlagen
---
SL/CT.pm | 4 +++-
SL/IC.pm | 2 +-
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/SL/CT.pm b/SL/CT.pm
index e97905ae8..c6f55da3b 100644
--- a/SL/CT.pm
+++ b/SL/CT.pm
@@ -391,7 +391,9 @@ sub save_vendor {
} else {
my $uid = time;
$uid .= $form->{login};
-
+ my $uid = rand() . time;
+ $uid .= $form->{login};
+ $uid = substr($uid, 2, 75);
$query = qq|INSERT INTO vendor (name)
VALUES ('$uid')|;
$dbh->do($query) || $form->dberror($query);
diff --git a/SL/IC.pm b/SL/IC.pm
index 42959fe6b..48c799675 100644
--- a/SL/IC.pm
+++ b/SL/IC.pm
@@ -258,7 +258,7 @@ sub save {
$dbh->do($query) || $form->dberror($query);
} else {
- my $uid = time;
+ my $uid = rand() . time;
$uid .= $form->{login};
$query = qq|SELECT p.id FROM parts p
--
2.20.1