Displaying 4 results from an estimated 4 matches for "rosh_dir_arg".
2009 Mar 06
4
rosh patch
Hey Guys,
Below is a patch for the com32/rosh/rosh.c from tonights syslinx git.
The patch does the following:
1) changes the rosh_issp to use an if instead of a case for this simple
test.
2) changes the rosh_dir_arg function to move the readdir() to inside the
while test.
This will let me go through my APUE book.
Let me know if you have any questions.
Keith
--- rosh.orig 2009-03-05 20:32:59.000000000 -0500
+++ rosh.c 2009-03-05 22:09:55.000000000 -0500
@@ -60,11 +60,11 @@
*/
int rosh_issp(char in...
2009 Mar 05
0
[PATCH 5/5] COM32/rosh: Improvements
...+ ROSH_FREE_DIRENT(de);
+ de = readdir(d);
+ }
+} /* rosh_ls_arg_dir */
+
/* Simple directory listing for one argument (file/directory) based on
* filestr and pwdstr
* ifilstr input filename/directory name to list
* pwdstr Present Working Directory string
+ * optarr Option Array
*/
-void rosh_dir_arg(const char *ifilstr, const char *pwdstr)
+void rosh_ls_arg(const char *ifilstr, const char *pwdstr, const int *optarr)
{
struct stat fdstat;
int status;
@@ -356,15 +614,7 @@ void rosh_dir_arg(const char *ifilstr, const char *pwdstr)
char filestr[ROSH_PATH_SZ + 1];
int filepos;
DIR *d;
-...
2009 Feb 15
2
COM32 module: Read-Only shell
...pwdstr);
+ printf("CFG: '%s'\n", syslinux_config_file());
+} /* rosh_cfg */
+
+/* Simple directory listing for one argument (file/directory) based on
+ * filestr and pwdstr
+ * ifilstr input filename/directory name to list
+ * pwdstr Present Working Directory string
+ */
+void rosh_dir_arg(const char *ifilstr, const char *pwdstr)
+{
+ struct stat fdstat;
+ int status;
+ int fd;
+ char filestr[ROSH_PATH_SZ + 1];
+ int filepos;
+ DIR *d;
+ struct dirent *de;
+#ifdef DO_DEBUG
+ char filestr2[ROSH_PATH_SZ + 1];
+ int fd2, file2pos;
+#ifdef __COM32__
+// int inchar;
+ char ty;
+#endif /*...
2010 Jun 27
1
[PATCH] ROSH: Upgraded
...= 0)
+ ROSH_DEBUG("0 files found");
+} /* rosh_ls_arg_dir */
+
/* Simple directory listing for one argument (file/directory) based on
* filestr and pwdstr
* ifilstr input filename/directory name to list
* pwdstr Present Working Directory string
+ * optarr Option Array
*/
-void rosh_dir_arg(const char *ifilstr, const char *pwdstr)
+void rosh_ls_arg(const char *filestr, const int *optarr)
{
struct stat fdstat;
int status;
- int fd;
- char filestr[ROSH_PATH_SZ + 1];
- int filepos;
+// char filestr[ROSH_PATH_SZ];
+// int filepos;
DIR *d;
- struct diren...