Changeset 14830


Ignorieren:
Zeitstempel:
22.08.2018 06:07:35 (vor 5 Wochen)
Autor:
er13
Nachricht:

enforce urlader settings patch: properly escape single quotes

Datei:
1 bearbeitet

Legende:

Unverändert
Hinzugefügt
Entfernt
  • trunk/patches/scripts/101-enforce_urlader-settings.sh

    r11282 r14830  
    1010 
    1111    if [ -n "$FREETZ_ENFORCE_URLADER_SETTING_FIRMWARE_VERSION" ]; then 
    12         echo 'firmware_version="$(echo $(grep firmware_version /proc/sys/urlader/environment) | cut -d' ' -f2)"' 
     12        echo 'firmware_version="$(echo $(grep firmware_version /proc/sys/urlader/environment) | cut -d'"' '"' -f2)"' 
    1313        echo 'if [ "$firmware_version" != "'$FREETZ_ENFORCE_URLADER_SETTING_FIRMWARE_VERSION'" ]; then' 
    1414        echo 'echo firmware_version '$FREETZ_ENFORCE_URLADER_SETTING_FIRMWARE_VERSION' > /proc/sys/urlader/environment' 
     
    1717    fi >> "${FILESYSTEM_MOD_DIR}/etc/init.d/rc.S" 
    1818    if [ -n "$FREETZ_ENFORCE_URLADER_SETTING_MY_IPADDRESS" ]; then 
    19         echo 'my_ipaddress="$(echo $(grep my_ipaddress /proc/sys/urlader/environment) | cut -d' ' -f2)"' 
     19        echo 'my_ipaddress="$(echo $(grep my_ipaddress /proc/sys/urlader/environment) | cut -d'"' '"' -f2)"' 
    2020        echo '[ "$my_ipaddress" = '$FREETZ_ENFORCE_URLADER_SETTING_MY_IPADDRESS' ] || echo my_ipaddress '$FREETZ_ENFORCE_URLADER_SETTING_MY_IPADDRESS' > /proc/sys/urlader/environment' 
    2121    fi >> "${FILESYSTEM_MOD_DIR}/etc/init.d/rc.S" 
    2222    if [ -n "$FREETZ_ENFORCE_URLADER_SETTING_PRODUCTID" ]; then 
    23         echo 'ProductID="$(echo $(grep ProductID /proc/sys/urlader/environment) | cut -d' ' -f2)"' 
     23        echo 'ProductID="$(echo $(grep ProductID /proc/sys/urlader/environment) | cut -d'"' '"' -f2)"' 
    2424        echo '[ "$ProductID" = '$FREETZ_ENFORCE_URLADER_SETTING_PRODUCTID' ] || echo ProductID '$FREETZ_ENFORCE_URLADER_SETTING_PRODUCTID' > /proc/sys/urlader/environment' 
    2525    fi >> "${FILESYSTEM_MOD_DIR}/etc/init.d/rc.S" 
Hinweis: Hilfe zur Verwendung der Changeset-Ansicht finden Sie unter TracChangeset.