pacman-key: use mapfile over read

Signed-off-by: Dave Reisner <dreisner@archlinux.org>
This commit is contained in:
Dave Reisner 2012-05-12 22:15:09 -04:00 committed by Dan McGee
parent 9d3e59e311
commit fc9002188b
1 changed files with 1 additions and 1 deletions

View File

@ -318,7 +318,7 @@ populate_keyring() {
local -A revoked_ids
for keyring in "${KEYRINGIDS[@]}"; do
if [[ -f "${KEYRING_IMPORT_DIR}/${keyring}-revoked" ]]; then
IFS=$'\n' read -r -d '' -a keys < "${KEYRING_IMPORT_DIR}/${keyring}-revoked"
mapfile -t keys < "${KEYRING_IMPORT_DIR}/${keyring}-revoked"
while IFS=: read _ _ _ _ key_id _; do
if [[ -n $key_id ]]; then
# Mark this key to be disabled