[libvirt] [PATCH] util: fix a typo error on virStrncpy

* src/util/util.c: fix a typo error on virStrncpy. --- src/util/util.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/src/util/util.c b/src/util/util.c index 0ca81df..1080823 100644 --- a/src/util/util.c +++ b/src/util/util.c @@ -1754,7 +1754,7 @@ virStrncpy(char *dest, const char *src, size_t n, size_t destbytes) return NULL; ret = strncpy(dest, src, n); - /* strncpy NULL terminates iff the last character is \0. Therefore + /* strncpy NULL terminates if the last character is \0. Therefore * force the last byte to be \0 */ dest[n] = '\0'; -- 1.7.1

2011/7/15 <ajia@redhat.com>:
* src/util/util.c: fix a typo error on virStrncpy. --- src/util/util.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/util/util.c b/src/util/util.c index 0ca81df..1080823 100644 --- a/src/util/util.c +++ b/src/util/util.c @@ -1754,7 +1754,7 @@ virStrncpy(char *dest, const char *src, size_t n, size_t destbytes) return NULL;
ret = strncpy(dest, src, n); - /* strncpy NULL terminates iff the last character is \0. Therefore + /* strncpy NULL terminates if the last character is \0. Therefore
This is not necessarily a typo. iff is short for 'if and only if'. -- Matthias Bolte http://photron.blogspot.com

On 07/15/2011 05:11 PM, Matthias Bolte wrote:
2011/7/15<ajia@redhat.com>:
* src/util/util.c: fix a typo error on virStrncpy. --- src/util/util.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/src/util/util.c b/src/util/util.c index 0ca81df..1080823 100644 --- a/src/util/util.c +++ b/src/util/util.c @@ -1754,7 +1754,7 @@ virStrncpy(char *dest, const char *src, size_t n, size_t destbytes) return NULL;
ret = strncpy(dest, src, n); - /* strncpy NULL terminates iff the last character is \0. Therefore + /* strncpy NULL terminates if the last character is \0. Therefore This is not necessarily a typo. iff is short for 'if and only if'.
Matthias, thanks,I know what the 'iff' is now :-) Regards, Alex
participants (3)
-
ajia@redhat.com
-
Alex Jia
-
Matthias Bolte