add comments

pull/6/head
yuqing 2016-02-03 16:03:08 +08:00
parent 39b0a94eb2
commit c6a41be8b9
2 changed files with 4 additions and 4 deletions

View File

@ -17,7 +17,7 @@
#define FAST_WRITE_BUFF_SIZE 256 * 1024
typedef struct fast_if_config {
char name[IF_NAMESIZE];
char name[IF_NAMESIZE]; //if name
char mac[32];
char ipv4[IP_ADDRESS_SIZE];
char ipv6[48];
@ -340,8 +340,8 @@ int gethostaddrs(char **if_alias_prefixes, const int prefix_count, \
/** get local if configs
* parameters:
* if_configs: store the if configs
* max_count: max ip address (max ip_addrs elements)
* count: store the ip address count
* max_count: max ifconfig elements
* count: store the ifconfig count
* return: error no, 0 success, != 0 fail
*/
int getifconfigs(FastIFConfig *if_configs, const int max_count, int *count);

View File

@ -121,7 +121,7 @@ int main(int argc, char *argv[])
printf("procs: %d\n", info.procs);
}
stat("/etc/passwd", &st);
stat("/dev/zero", &st);
printf("file inode: %ld\n", (long)st.st_ino);
printf("file device: %ld\n", (long)st.st_dev);
printf("file access time: %d.%ld\n", (int)st.st_atime, st.st_atimensec);