OSDN Git Service

[fix] : Added architecture check
authorhayao <hayao@fascode.net>
Sun, 10 Oct 2021 11:23:05 +0000 (20:23 +0900)
committerhayao <hayao@fascode.net>
Sun, 10 Oct 2021 11:23:05 +0000 (20:23 +0900)
tools/locale.sh

index 3e502b5..dbb1a4a 100755 (executable)
@@ -45,6 +45,10 @@ gen_locale_list() {
         msg_error "No architecture specified." 
         exit 1
     fi
+    if [[ ! -f "${script_path}/system/locale-${arch}" ]]; then
+        msg_error "Missing architecture ${arch}"
+        exit 1
+    fi
     local _locale
     for _locale in $(grep -h -v ^'#' "${script_path}/system/locale-${arch}" | grep -v ^$ | getclm 1); do 
         localelist+=("${_locale}")