Skip to content

Instantly share code, notes, and snippets.

@y109
Forked from rikioy/int2ip.cpp
Created May 13, 2016 19:26
Show Gist options
  • Save y109/29e039164ccf7bd09a6955f34ea386cc to your computer and use it in GitHub Desktop.
Save y109/29e039164ccf7bd09a6955f34ea386cc to your computer and use it in GitHub Desktop.
int2ip
string int2ip(unsigned int ip_num){
struct in_addr in;
in.s_addr = ip_num;
return inet_ntoa(in);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment