search for: pwdstr

Displaying 5 results from an estimated 5 matches for "pwdstr".

2010 Jun 27
1
[PATCH] ROSH: Upgraded
...m - All Rights Reserved + * Copyright 2008-2010 Gene Cumm - All Rights Reserved * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -20,22 +20,24 @@ /* * ToDos: - * Change functions to use pwdstr - * In rosh_run() Reparse cmdstr relative to pwdstr + * rosh_ls(): sorted; then multiple columns */ -// #define DO_DEBUG 1 - /* Uncomment the above line for debugging output; Comment to remove */ -// #define DO_DEBUG2 1 - /* Uncomment the above line for super-debugging output; Must have regular...
2009 Feb 15
2
COM32 module: Read-Only shell
.../* + * rosh.c + * + * Read-Only shell; Simple shell system designed for SYSLINUX-derivitives. + * Provides minimal commands utilizing the console via stdout/stderr as the + * sole output devices. Designed to compile for Linux for testing/debugging. + */ + +/* + * ToDos: + * Change functions to use pwdstr + * In rosh_run() Reparse cmdstr relative to pwdstr + */ + +// #define DO_DEBUG 1 + /* Uncomment the above line for debugging output; Comment to remove */ +// #define DO_DEBUG2 1 + /* Uncomment the above line for super-debugging output; Must have regular debugging enabled; Comment to remove */ + +#...
2009 Mar 05
0
[PATCH 5/5] COM32/rosh: Improvements
...e Cumm - All Rights Reserved + * Copyright 2008-2009 Gene Cumm - All Rights Reserved * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -22,20 +22,24 @@ * ToDos: * Change functions to use pwdstr * In rosh_run() Reparse cmdstr relative to pwdstr + * rosh_ls(): sorted; then multiple columns */ -// #define DO_DEBUG 1 - /* Uncomment the above line for debugging output; Comment to remove */ -// #define DO_DEBUG2 1 - /* Uncomment the above line for super-debugging output; Must have regular...
2009 Feb 11
1
[PATCH 1/1] COM32 API: Add functions for directory use
...wd.c @@ -0,0 +1,29 @@ +/* + * getcwd.c + */ + +#include <syslinux/config.h> +#include <klibc/compiler.h> +#include <com32.h> + +#include <dirent.h> +#include <stdio.h> +#include <errno.h> + +char *getcwd(char *buf, size_t size) +{ + static com32sys_t reg; + char *pwdstr, *ret; + + reg.eax.w[0] = 0x001f; + __intcall(0x22, &reg, &reg); + pwdstr = MK_PTR(reg.es, reg.ebx.w[0]); + if ((strlen(pwdstr) < size) && (buf != NULL)) { + strcpy(buf, pwdstr); + ret = buf; + } else { + ret = NULL; + errno = ERANGE; + } + return ret; +} diff --git a/com32/...
2008 Dec 04
0
[PATCH 1/1] COM32: Add directory functions
...wd.c @@ -0,0 +1,29 @@ +/* + * getcwd.c + */ + +#include <syslinux/config.h> +#include <klibc/compiler.h> +#include <com32.h> + +#include <dirent.h> +#include <stdio.h> +#include <errno.h> + +char *getcwd(char *buf, size_t size) +{ + static com32sys_t reg; + char *pwdstr, *ret; + + reg.eax.w[0] = 0x001e; + __intcall(0x22, &reg, &reg); + pwdstr = MK_PTR(reg.es, reg.ebx.w[0]); + if ((strlen(pwdstr) < size) && (buf != NULL)) { + strcpy(buf, pwdstr); + ret = buf; + } else { + ret = NULL; + errno = ERANGE; + } + return ret; +} diff --git a/com32/...