mirror of
https://github.com/freebsd/freebsd-src
synced 2024-10-15 12:54:27 +00:00
Don't leave dodgy looking spaces in HISMACADDR
This commit is contained in:
parent
a12856cfee
commit
b5c025b829
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=86762
|
@ -350,9 +350,9 @@ Spawn(const char *prog, const char *acname, const char *provider,
|
||||||
if (sz >= sizeof(struct ether_header)) {
|
if (sz >= sizeof(struct ether_header)) {
|
||||||
|
|
||||||
macaddr = ((struct ether_header *)request)->ether_shost;
|
macaddr = ((struct ether_header *)request)->ether_shost;
|
||||||
snprintf(env, sizeof(env), "%s=%2x:%2x:%2x:%2x:%2x:%2x", HISMACADDR,
|
snprintf(env, sizeof(env), "%s=%x:%x:%x:%x:%x:%x", HISMACADDR,
|
||||||
macaddr[0], macaddr[1], macaddr[2], macaddr[3], macaddr[4],
|
macaddr[0], macaddr[1], macaddr[2], macaddr[3], macaddr[4],
|
||||||
macaddr[5]);
|
macaddr[5]);
|
||||||
if (putenv(env) != 0)
|
if (putenv(env) != 0)
|
||||||
syslog(LOG_INFO, "putenv: cannot set %s: %m", env);
|
syslog(LOG_INFO, "putenv: cannot set %s: %m", env);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue