Install databases atomically (thanks to Henrik K)
1 files changed, 2 insertions(+), 1 deletions(-)

M fetch-sanesecurity-sigs
M fetch-sanesecurity-sigs +2 -1
@@ 218,7 218,8 @@ do
 
 	# Now we can actually install this database
 	echo "Installing $db_name into $clamd_dbdir/sanesecurity-$db_name"
-	if cp -p "$db" "$clamd_dbdir/sanesecurity-$db_name"
+	if cp -p "$db" "$clamd_dbdir/sanesecurity-$db_name.tmp" && \
+		mv -f "$clamd_dbdir/sanesecurity-$db_name.tmp" "$clamd_dbdir/sanesecurity-$db_name"
 	then
 		installed=$((installed+1))