Commit Graph

21 Commits

Author SHA1 Message Date
Joel Sherrill
68baf9eead libmisc/shell/*: Relicense to 2-BSD
Many files in this directory were by persons and organizations
that have previously given relicensing permission. git history
was used to confirm authorship and contributions on files which
had unclear or missing copyrights.

Update #3053.
2025-03-01 20:21:56 +00:00
Sebastian Huber
f97536dcd3 basdefs.h: Add and use RTEMS_UNUSED 2015-10-26 09:13:19 +01:00
Sebastian Huber
12278585c6 shell: Make rtems_shell_main_joel() static 2014-11-20 10:30:25 +01:00
Chris Johns
c49985691f Change all references of rtems.com to rtems.org. 2014-03-21 08:10:47 +11:00
Gedare Bloom
96654dcc1a shell: Out-of-bounds access
In case the length of cwd path plus the userScriptName exceeds
PATH_MAX (255), the strncat calls will overflow scriptFile. Also
check for getcwd failure.
2013-09-05 12:15:27 -04:00
Sebastian Huber
f2d9fda780 shell: Include missing header file 2013-07-22 16:45:58 +02:00
Joel Sherrill
9b4422a251 Remove All CVS Id Strings Possible Using a Script
Script does what is expected and tries to do it as
smartly as possible.

+ remove occurrences of two blank comment lines
  next to each other after Id string line removed.
+ remove entire comment blocks which only exited to
  contain CVS Ids
+ If the processing left a blank line at the top of
  a file, it was removed.
2012-05-11 08:44:13 -05:00
Joel Sherrill
f16c0591a2 2011-01-17 Alin Rus <alin.codejunkie@gmail.com>
* posix/src/aio_cancel.c: Fixed ending of if braces.

2011-01-17	Alin Rus <alin.codejunkie@gmail.com>

	* posix/src/aio_misc.c: Add debug information. Fixed idle_threads/
	active_threads issues. Fixed infinite loop in rtems_aio_handle().
2011-01-17 22:12:48 +00:00
Joel Sherrill
db2c804aa8 2010-02-28 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/shell/shell_script.c: Fix typo.
2010-02-28 20:14:10 +00:00
Ralf Corsepius
0893220b2a Whitespace removal. 2009-11-29 12:12:39 +00:00
Joel Sherrill
48751ab095 2009-07-23 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/Makefile.am, libmisc/shell/main_chmod.c,
	libmisc/shell/main_mdump.c, libmisc/shell/main_medit.c,
	libmisc/shell/main_mfill.c, libmisc/shell/main_mmove.c,
	libmisc/shell/main_msdosfmt.c, libmisc/shell/main_mwdump.c,
	libmisc/shell/main_sleep.c, libmisc/shell/main_umask.c,
	libmisc/shell/shell_script.c, libmisc/stringto/stringto.h,
	libmisc/stringto/stringto_template.h: Convert return type from bool
	to rtems_status_code and add rtems_string_to_pointer. Perform
	associated clean up and changes for return type change.
	* libmisc/stringto/stringtopointer.c: New file.
2009-07-23 14:32:34 +00:00
Joel Sherrill
35d09baa84 2009-07-22 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/Makefile.am, libmisc/shell/main_chmod.c,
	libmisc/shell/main_mdump.c, libmisc/shell/main_medit.c,
	libmisc/shell/main_mfill.c, libmisc/shell/main_mmove.c,
	libmisc/shell/main_msdosfmt.c, libmisc/shell/main_mwdump.c,
	libmisc/shell/main_sleep.c, libmisc/shell/main_umask.c,
	libmisc/shell/shell.h, libmisc/shell/shell_script.c,
	libmisc/stringto/stringto_template.h: Convert all shell code to use
	stringto.h mehods with better error checking.
	* libmisc/shell/str2int.c: Removed.
2009-07-22 15:17:37 +00:00
Joel Sherrill
6d8720c481 2009-05-10 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/shell/login_prompt.c, libmisc/shell/shell_script.c,
	rtems/include/rtems/rtems/timer.h: Fix warnings.
2009-05-10 14:55:43 +00:00
Ralf Corsepius
031deada15 Add __attribute__((unused)) to unused function args. 2009-01-02 13:04:13 +00:00
Joel Sherrill
b079fe33e4 2008-10-02 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/shell/main_cp.c, libmisc/shell/main_ls.c,
	libmisc/shell/main_mv.c, libmisc/shell/main_netstats.c,
	libmisc/shell/main_rm.c, libmisc/shell/shell_script.c: Newlib >
	1.16.0 requires __need_getopt_newlib to be defined to get visibility
	on the reentrancy extensions.
2008-10-02 20:16:16 +00:00
Ralf Corsepius
ee0c82f413 Add missing prototypes. 2008-08-02 05:16:26 +00:00
Joel Sherrill
e6ee171252 2008-07-23 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/shell/shell_script.c: Clean up code for command not found
	including the error message.
2008-07-23 20:28:13 +00:00
Joel Sherrill
9a9851dd4a 2008-07-02 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/shell/shell_script.c: Remove unused function.
2008-07-02 14:26:24 +00:00
Chris Johns
55c64fc9cd 2008-04-12 Chris Johns <chrisj@rtems.org>
* libmisc/shell/shell.c, libmisc/shell/shell.h,
	libmisc/shell/shell_script.c: Add support to echo the commands to
	stdout. This is useful with the -v script option to show commands
	as the run. Also added support to chdir to the directory the task
	invoking the script is in.
	* libmisc/shell/extern-cp.h, libmisc/shell/main_cp.c,
	libmisc/shell/utils-cp.c: Update tro the latest FreeBSD version.
	* libcsupport/Makefile.am, libcsupport/src/fchown.c: Add fchown
	support.
2008-04-11 22:57:54 +00:00
Joel Sherrill
85659eeeb6 2008-03-07 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/shell/main_cp.c, libmisc/shell/main_netstats.c,
	libmisc/shell/shell_script.c: Add memset() of getopt_data to
	ensure it is zeroed out each time we use getopt_r().
	* libmisc/shell/shell.c: Do not echo commands if input is not a tty.
	This makes the scripts behave more like UNIX scripts.
2008-03-07 20:09:36 +00:00
Joel Sherrill
a3ddb08bec 2008-03-04 Joel Sherrill <joel.sherrill@oarcorp.com>
* libmisc/Makefile.am, libmisc/shell/main_cp.c,
	libmisc/shell/main_cpuuse.c, libmisc/shell/main_date.c,
	libmisc/shell/main_mallocinfo.c, libmisc/shell/main_netstats.c,
	libmisc/shell/main_perioduse.c, libmisc/shell/main_stackuse.c,
	libmisc/shell/main_wkspaceinfo.c, libmisc/shell/print_heapinfo.c,
	libmisc/shell/shell.c, libmisc/shell/shell.h,
	libmisc/shell/shell_makeargs.c, libmisc/shell/shellconfig.c,
	libmisc/shell/shellconfig.h, libmisc/shell/write_file.c: Add initial
	capability to automatically execute a script from the filesystem. Add
	echo command from NetBSD and sleep command.
	* libmisc/shell/main_echo.c, libmisc/shell/main_sleep.c,
	libmisc/shell/shell_script.c: New files.
2008-03-05 02:49:35 +00:00