forked from Imagelibrary/rtems
2010-02-24 Chris Johns <chrisj@rtems.org>
* libmisc/shell/main_msdosfmt.c, libmisc/shell/shellconfig.h: Fix
the alias as I did understand how it worked.
* libfs/src/dosfs/msdos_format.c: Test for a block device.
This commit is contained in:
@@ -1,3 +1,10 @@
|
||||
2010-02-24 Chris Johns <chrisj@rtems.org>
|
||||
|
||||
* libmisc/shell/main_msdosfmt.c, libmisc/shell/shellconfig.h: Fix
|
||||
the alias as I did understand how it worked.
|
||||
|
||||
* libfs/src/dosfs/msdos_format.c: Test for a block device.
|
||||
|
||||
2010-02-23 Chris Johns <chrisj@rtems.org>
|
||||
|
||||
* libfs/src/rfs/rtems-rfs-dir.c: Fix printf format warning for a
|
||||
|
||||
@@ -910,7 +910,7 @@ int msdos_format
|
||||
|
||||
/* rtems feature: no block devices, all are character devices */
|
||||
if ((ret_val == 0) &&
|
||||
(!S_ISCHR(stat_buf.st_mode))) {
|
||||
(!S_ISBLK(stat_buf.st_mode))) {
|
||||
errno = ENOTTY;
|
||||
ret_val = -1;
|
||||
}
|
||||
|
||||
@@ -170,6 +170,15 @@ rtems_shell_cmd_t rtems_shell_MSDOSFMT_Command = {
|
||||
"mkdos " OPTIONS " path # format disk", /* usage */
|
||||
"files", /* topic */
|
||||
rtems_shell_main_msdos_format, /* command */
|
||||
"msdosfmt", /* alias */
|
||||
NULL, /* alias */
|
||||
NULL /* next */
|
||||
};
|
||||
|
||||
rtems_shell_cmd_t rtems_shell_MSDOSFMT_Alias = {
|
||||
"msdosfmt", /* name */
|
||||
NULL, /* usage */
|
||||
"files", /* topic */
|
||||
NULL, /* command */
|
||||
&rtems_shell_MSDOSFMT_Command, /* alias */
|
||||
NULL /* next */
|
||||
};
|
||||
|
||||
@@ -52,6 +52,7 @@ extern rtems_shell_cmd_t rtems_shell_CHMOD_Command;
|
||||
extern rtems_shell_cmd_t rtems_shell_CAT_Command;
|
||||
extern rtems_shell_cmd_t rtems_shell_MKRFS_Command;
|
||||
extern rtems_shell_cmd_t rtems_shell_MSDOSFMT_Command;
|
||||
extern rtems_shell_cmd_t rtems_shell_MSDOSFMT_Alias;
|
||||
extern rtems_shell_cmd_t rtems_shell_MV_Command;
|
||||
extern rtems_shell_cmd_t rtems_shell_RM_Command;
|
||||
extern rtems_shell_cmd_t rtems_shell_LN_Command;
|
||||
@@ -303,6 +304,7 @@ extern rtems_shell_filesystems_t *rtems_shell_Mount_filesystems[];
|
||||
!defined(CONFIGURE_SHELL_NO_COMMAND_MSDOSFMT)) || \
|
||||
defined(CONFIGURE_SHELL_COMMAND_MSDOSFMT)
|
||||
&rtems_shell_MSDOSFMT_Command,
|
||||
&rtems_shell_MSDOSFMT_Alias,
|
||||
#endif
|
||||
#if (defined(CONFIGURE_SHELL_COMMANDS_ALL) && \
|
||||
!defined(CONFIGURE_SHELL_NO_COMMAND_MV)) || \
|
||||
|
||||
Reference in New Issue
Block a user