aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2014-10-31 10:05:20 +0200
committerSergey Poznyakoff <gray@gnu.org.ua>2015-12-17 15:26:28 +0200
commit9f5d2456094abd11187a24c3a94c74064b5da53d (patch)
treefd89e492a4bc0e9ff0a3ddd626c527e225d9a780 /doc
parent5ce27a8cdee32f53a922c459a4f9beae307543f7 (diff)
downloadgrecs-9f5d2456094abd11187a24c3a94c74064b5da53d.tar.gz
grecs-9f5d2456094abd11187a24c3a94c74064b5da53d.tar.bz2
wordsplit: minor fixes
Diffstat (limited to 'doc')
-rw-r--r--doc/wordsplit.310
1 files changed, 5 insertions, 5 deletions
diff --git a/doc/wordsplit.3 b/doc/wordsplit.3
index 3c666bc..abb1f34 100644
--- a/doc/wordsplit.3
+++ b/doc/wordsplit.3
@@ -14,7 +14,7 @@
.\" You should have received a copy of the GNU General Public License
.\" along with Grecs. If not, see <http://www.gnu.org/licenses/>.
.\"
-.TH WORDSPLIT 3 "October 30, 2014" "GRECS" "Grecs User Reference"
+.TH WORDSPLIT 3 "October 31, 2014" "GRECS" "Grecs User Reference"
.SH NAME
wordsplit \- split string into words
.SH SYNOPSIS
@@ -47,8 +47,8 @@ using a set of rules governed by \fIflags\fR. Depending on
tilde expansion, variable expansion, quote removal, command
substitution, and path expansion. On success, the function returns 0
and stores the words found in the member \fBws_wordv\fR and the number
-of words in the member \fBws_wordc\fR. On error, -1 is returned and
-error code is stored in \fBws_errno\fR.
+of words in the member \fBws_wordc\fR. On error, a non-zero error
+code is returned.
.PP
The function \fBwordsplit_len\fR acts similarly, except that it
accesses only first \fBlen\fR bytes of the string \fIs\fR, which is
@@ -940,7 +940,7 @@ static int runcmd(char **ret, const char *str, size_t len,
extern char **environ;
-/* Parse \fIs\fR much as shell does. Return the array of words on
+/* Parse \fIs\fR much as shell does. Return array of words on
succes, and NULL on error.
*/
char **shell_parse(char *s)
@@ -953,7 +953,7 @@ char **shell_parse(char *s)
/* Initialize \fIws\fR */
ws.ws_env = (const char **) environ;
ws.ws_command = runcmd;
- /* Call \fBwordsplit\fR. Let it report the errors. */
+ /* Call \fBwordsplit\fR. Let it report errors, if any. */
rc = wordsplit(s, &ws,
WRDSF_QUOTE | WRDSF_SQUEEZE_DELIMS | WRDSF_PATHEXPAND
| WRDSF_SHOWERR);

Return to:

Send suggestions and report system problems to the System administrator.