From mboxrd@z Thu Jan 1 00:00:00 1970 From: stefano babic Date: Wed, 15 Oct 2008 14:01:59 +0200 Subject: [U-Boot] [PATCH] Handle environment variables like commands In-Reply-To: <20081015110156.306B581C99CD@gemini.denx.de> References: <1224065384-24171-1-git-send-email-sbabic@denx.de> <20081015104550.GB6881@colossus> <20081015110156.306B581C99CD@gemini.denx.de> Message-ID: <48F5DBB7.4070307@babic.homelinux.org> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de Wolfgang Denk wrote: > Good catch. Yes, this must be prevented. Any variable named "builtin" > must be ignored here - i. e. we should issue an erro when someone > tries a "setenv", and ignore this variable explicitly (just in case > someone sneaks this into the default environment, or uses un-fixed > Linux tools to create such a variable). I know, I wanted to know which is the preferred method to avoid that. One way is to avoid to set the variable, as you suggest. The other way is never execute a variable with the name "builtin" in the command interpreter: "setenv builtin " remains possible but "builtin " calls always the U-Boot commands. Best regards, Stefano Babic -- stefano GPG Key: 0x55814DDE Fingerprint 4E85 2A66 4CBA 497A 2A7B D3BF 5973 F216 5581 4DDE