Changeset 959d2ec in mainline for uspace/app
- Timestamp:
- 2013-05-08T10:29:45Z (12 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- d242cb6
- Parents:
- 9f029aa
- Location:
- uspace/app
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/app/dnsres/dnsres.c
r9f029aa r959d2ec 50 50 int rc; 51 51 dnsr_hostinfo_t *hinfo; 52 char *hname; 52 53 char *saddr; 53 54 … … 57 58 } 58 59 59 rc = dnsr_name2host(argv[1], &hinfo); 60 hname = argv[1]; 61 62 rc = dnsr_name2host(hname, &hinfo); 60 63 if (rc != EOK) { 61 64 printf(NAME ": Error resolving '%s'.\n", argv[1]); … … 70 73 } 71 74 72 printf("Host name: %s address: %s\n", hinfo->name, saddr); 75 printf("Host name: %s\n", hname); 76 if (str_cmp(hname, hinfo->cname) != 0) 77 printf("Canonical name: %s\n", hinfo->cname); 78 printf("Address: %s\n", saddr); 79 73 80 dnsr_hostinfo_destroy(hinfo); 74 81 free(saddr); -
uspace/app/ping/ping.c
r9f029aa r959d2ec 234 234 235 235 if (hinfo != NULL) { 236 rc = asprintf(&sdest, "%s (%s)", hinfo-> name, adest);236 rc = asprintf(&sdest, "%s (%s)", hinfo->cname, adest); 237 237 if (rc < 0) { 238 238 printf(NAME ": Out of memory.\n");
Note:
See TracChangeset
for help on using the changeset viewer.