summaryrefslogtreecommitdiff
path: root/libbb
diff options
context:
space:
mode:
authorDenis Vlasenko2007-09-25 18:35:28 +0000
committerDenis Vlasenko2007-09-25 18:35:28 +0000
commit6a5377ac14bec2f2ae62c4ec085ff3b149cc11ad (patch)
treebb2200121abb55f06facbe8793c649ae90f53717 /libbb
parentea7645bab62c6f68c755cf717662bceaa04858ed (diff)
downloadbusybox-6a5377ac14bec2f2ae62c4ec085ff3b149cc11ad.zip
busybox-6a5377ac14bec2f2ae62c4ec085ff3b149cc11ad.tar.gz
documentation bits in comments, no code changes
Diffstat (limited to 'libbb')
-rw-r--r--libbb/lineedit.c5
-rw-r--r--libbb/skip_whitespace.c2
2 files changed, 6 insertions, 1 deletions
diff --git a/libbb/lineedit.c b/libbb/lineedit.c
index 62f8949..a018a53 100644
--- a/libbb/lineedit.c
+++ b/libbb/lineedit.c
@@ -1253,6 +1253,11 @@ static void win_changed(int nsig)
#undef CTRL
#define CTRL(a) ((a) & ~0x40)
+/* Returns:
+ * -1 on read errors or EOF, or on bare Ctrl-D.
+ * 0 on ctrl-C,
+ * >0 length of input string, including terminating '\n'
+ */
int read_line_input(const char* prompt, char* command, int maxsize, line_input_t *st)
{
int lastWasTab = FALSE;
diff --git a/libbb/skip_whitespace.c b/libbb/skip_whitespace.c
index bdfb97d..87b5f23 100644
--- a/libbb/skip_whitespace.c
+++ b/libbb/skip_whitespace.c
@@ -11,7 +11,7 @@
char *skip_whitespace(const char *s)
{
- /* NB: isspace('0') returns 0 */
+ /* NB: isspace('\0') returns 0 */
while (isspace(*s)) ++s;
return (char *) s;