Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 336952
b: refs/heads/master
c: f426a36
h: refs/heads/master
v: v3
  • Loading branch information
K. Y. Srinivasan authored and Greg Kroah-Hartman committed Oct 30, 2012
1 parent 6235cfe commit 7d7f764
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: e64de3b96c1ba3c1de236a4a103ec21234a5849f
refs/heads/master: f426a36cecfea2cfd69c28ca5ba4f4bfae913f63
9 changes: 6 additions & 3 deletions trunk/tools/hv/hv_kvp_daemon.c
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ static char *os_major = "";
static char *os_minor = "";
static char *processor_arch;
static char *os_build;
static char *os_version;
static char *lic_version = "Unknown version";
static struct utsname uts_buf;

Expand Down Expand Up @@ -453,7 +454,9 @@ void kvp_get_os_info(void)
char *p, buf[512];

uname(&uts_buf);
os_build = uts_buf.release;
os_version = uts_buf.release;
os_build = strdup(uts_buf.release);

os_name = uts_buf.sysname;
processor_arch = uts_buf.machine;

Expand All @@ -462,7 +465,7 @@ void kvp_get_os_info(void)
* string to be of the form: x.y.z
* Strip additional information we may have.
*/
p = strchr(os_build, '-');
p = strchr(os_version, '-');
if (p)
*p = '\0';

Expand Down Expand Up @@ -1649,7 +1652,7 @@ int main(void)
strcpy(key_name, "OSMinorVersion");
break;
case OSVersion:
strcpy(key_value, os_build);
strcpy(key_value, os_version);
strcpy(key_name, "OSVersion");
break;
case ProcessorArchitecture:
Expand Down

0 comments on commit 7d7f764

Please sign in to comment.