buildDotnetModule: unset TMPDIR instead of setting it empty

This was breaking nix-prefetch-url when running fetch-deps in nix-shell.

e.g.

    $ TMPDIR= nix-prefetch-url foo
    nix-prefetch-url: src/libutil/util.cc:119: nix::Path
    nix::canonPath(PathView, bool): Assertion `path != ""' failed. [2]
    881198 abort (core dumped)
This commit is contained in:
David McFarland 2023-06-23 15:08:57 -03:00
parent ee8ba995a7
commit cf9976de74

View File

@ -214,7 +214,7 @@ stdenvNoCC.mkDerivation (args // {
if [[ ''${TMPDIR:-} == /run/user/* ]]; then
# /run/user is usually a tmpfs in RAM, which may be too small
# to store all downloaded dotnet packages
TMPDIR=
unset TMPDIR
fi
export tmp=$(mktemp -td "deps-${pname}-XXXXXX")