projects
/
am-utils-6.1.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
041afdd
)
use sizeof var instead of constant.
author
Christos Zoulas
<christos@zoulas.com>
Wed, 17 Sep 2008 20:21:45 +0000
(20:21 +0000)
committer
Christos Zoulas
<christos@zoulas.com>
Wed, 17 Sep 2008 20:21:45 +0000
(20:21 +0000)
fixmount/fixmount.c
patch
|
blob
|
history
diff --git
a/fixmount/fixmount.c
b/fixmount/fixmount.c
index 8bbcb99f351671c6cafb009f271f047a1d118559..b95d1c45e2adc518ab6882d0ea80e9c20c217204 100644
(file)
--- a/
fixmount/fixmount.c
+++ b/
fixmount/fixmount.c
@@
-115,7
+115,7
@@
is_same_host(char *name1, char *name2, struct in_addr addr2)
} else if (!(he = gethostbyname(name1))) {
return 0;
} else {
- xstrlcpy(lasthost, name1,
MAXHOSTNAMELEN
);
+ xstrlcpy(lasthost, name1,
sizeof(lasthost)
);
memcpy(&addr1, he->h_addr, sizeof(addr1));
return (addr1.s_addr == addr2.s_addr);
}