# --- T2-COPYRIGHT-BEGIN --- # t2/package/*/embutils/which-wd.patch # Copyright (C) 2004 - 2026 The T2 SDE Project # SPDX-License-Identifier: GPL-2.0 or patched project license # --- T2-COPYRIGHT-END --- Fixed which to inject a . when nothing is found between colons, so current working directory binaries are located. - Rene Rebe --- embutils-0.17/which.c 2002-05-27 17:23:26.000000000 +0200 +++ embutils-0.17-free/which.c 2005-02-14 17:08:41.453217816 +0100 @@ -32,6 +32,7 @@ struct stat ss; char *bar=(char*)alloca(strlen(tmp)+strlen(argv[i])+5); int len=str_copy(bar,tmp); + if (len==0) { *bar='.'; len++; } bar[len]='/'; ++len; len+=str_copy(bar+len,argv[i]); bar[len]=0;