提交 9e185223 编写于 作者: M Miklos Vajna 提交者: Junio C Hamano

run-command documentation: fix "memset()" parameter

When initializing the struct async and struct child_process structures,
the documentation suggested "clearing" the structure with '0' instead of
'\0'.  It is enough to use integer zero here.
Signed-off-by: NMiklos Vajna <vmiklos@frugalware.org>
Signed-off-by: NJunio C Hamano <gitster@pobox.com>
上级 5f54de5b
......@@ -63,7 +63,7 @@ command to run in a sub-process.
The caller:
1. allocates and clears (memset(&chld, '0', sizeof(chld));) a
1. allocates and clears (memset(&chld, 0, sizeof(chld));) a
struct child_process variable;
2. initializes the members;
3. calls start_command();
......@@ -136,7 +136,7 @@ to produce output that the caller reads.
The caller:
1. allocates and clears (memset(&asy, '0', sizeof(asy));) a
1. allocates and clears (memset(&asy, 0, sizeof(asy));) a
struct async variable;
2. initializes .proc and .data;
3. calls start_async();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册