Skip to content

Commit

Permalink
display-managers module: improve variable quoting
Browse files Browse the repository at this point in the history
Fixes #20713, though I'm certain nixpkgs contains loads of places
without proper quoting, as (ba)sh unfortunately encourages that.

The only plus side is that most of such problems in nixpkgs aren't
actually security problems but mere annoyance to those who are foolish
enough to use "weird" characters in critical names.

(cherry picked from commit 8ebfce0)
  • Loading branch information
vcunat committed Nov 26, 2016
1 parent 066166b commit ece0cea
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions nixos/modules/services/x11/display-managers/default.nix
Expand Up @@ -82,12 +82,12 @@ let
# Speed up application start by 50-150ms according to
# http://kdemonkey.blogspot.nl/2008/04/magic-trick.html
rm -rf $HOME/.compose-cache
mkdir $HOME/.compose-cache
rm -rf "$HOME/.compose-cache"
mkdir "$HOME/.compose-cache"
# Work around KDE errors when a user first logs in and
# .local/share doesn't exist yet.
mkdir -p $HOME/.local/share
mkdir -p "$HOME/.local/share"
unset _DID_SYSTEMD_CAT
Expand Down Expand Up @@ -148,7 +148,7 @@ let
allowSubstitutes = false;
}
''
mkdir -p $out
mkdir -p "$out"
${concatMapStrings (n: ''
cat - > "$out/${n}.desktop" << EODESKTOP
[Desktop Entry]
Expand Down

0 comments on commit ece0cea

Please sign in to comment.