mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-06 19:41:15 +01:00
Use --list-fingerprint instead of process control in zero_length_keys.sh
Using kill and wait in this way may have been making windows builders unhappy.
This commit is contained in:
@@ -46,12 +46,7 @@ if [ -s "$DATA_DIR"/keys/secret_id_key ] && [ -s "$DATA_DIR"/keys/secret_onion_k
|
||||
exit 3
|
||||
else
|
||||
echo "Generating initial tor keys"
|
||||
$TOR --DataDirectory "$DATA_DIR" --PidFile "$DATA_DIR"/pid &
|
||||
TOR_PID=$!
|
||||
# generate SIGTERM, hopefully after the keys have been regenerated
|
||||
sleep 5
|
||||
kill $TOR_PID
|
||||
wait $TOR_PID
|
||||
$TOR --DataDirectory "$DATA_DIR" --list-fingerprint
|
||||
|
||||
# tor must successfully generate non-zero-length key files
|
||||
if [ -s "$DATA_DIR"/keys/secret_id_key ] && [ -s "$DATA_DIR"/keys/secret_onion_key ] &&
|
||||
@@ -88,12 +83,7 @@ if [ "$1" = "-z" ]; then
|
||||
fi
|
||||
|
||||
echo "Running tor again to check if it $FILE_DESC keys"
|
||||
$TOR --DataDirectory "$DATA_DIR" --PidFile "$DATA_DIR"/pid &
|
||||
TOR_PID=$!
|
||||
# generate SIGTERM, hopefully after the keys have been regenerated
|
||||
sleep 5
|
||||
kill $TOR_PID
|
||||
wait $TOR_PID
|
||||
$TOR --DataDirectory "$DATA_DIR" --list-fingerprint
|
||||
|
||||
#ls -lh "$DATA_DIR"/keys/ || exit 3
|
||||
|
||||
|
||||
Reference in New Issue
Block a user