summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJoe Hershberger <joe.hershberger@ni.com>2012-12-11 22:16:23 -0600
committerTom Rini <trini@ti.com>2012-12-13 11:46:55 -0700
commitbe11235ab802844e12d84921a38fd8ae4ddda080 (patch)
tree3ae5bb11aec34357c28bb46ed9ed66ad94f9f63f /include
parentec8a252cd492a7a409d6912aebeff34bb9e1e1e1 (diff)
downloadu-boot-imx-be11235ab802844e12d84921a38fd8ae4ddda080.zip
u-boot-imx-be11235ab802844e12d84921a38fd8ae4ddda080.tar.gz
u-boot-imx-be11235ab802844e12d84921a38fd8ae4ddda080.tar.bz2
env: Hide '.' variables in env print by default
When printing all variables with env print, don't print variables that begin with '.'. If env print is called with a '-a' switch, then include variables that begin with '.' (just like the ls command). Variables printed explicitly will be printed even without the -a. Signed-off-by: Joe Hershberger <joe.hershberger@ni.com>
Diffstat (limited to 'include')
-rw-r--r--include/search.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/include/search.h b/include/search.h
index fa00ea1..1e48deb 100644
--- a/include/search.h
+++ b/include/search.h
@@ -107,7 +107,7 @@ extern int hdelete_r(const char *__key, struct hsearch_data *__htab,
int __flag);
extern ssize_t hexport_r(struct hsearch_data *__htab,
- const char __sep, char **__resp, size_t __size,
+ const char __sep, int __flag, char **__resp, size_t __size,
int argc, char * const argv[]);
/*
@@ -120,9 +120,10 @@ extern int himport_r(struct hsearch_data *__htab,
const char *__env, size_t __size, const char __sep,
int __flag, int nvars, char * const vars[]);
-/* Flags for himport_r(), hdelete_r(), and hsearch_r() */
+/* Flags for himport_r(), hexport_r(), hdelete_r(), and hsearch_r() */
#define H_NOCLEAR (1 << 0) /* do not clear hash table before importing */
#define H_FORCE (1 << 1) /* overwrite read-only/write-once variables */
#define H_INTERACTIVE (1 << 2) /* indicate that an import is user directed */
+#define H_HIDE_DOT (1 << 3) /* don't print env vars that begin with '.' */
#endif /* search.h */