-
Notifications
You must be signed in to change notification settings - Fork 8
added IP address retrieval #205
base: master
Are you sure you want to change the base?
Conversation
This pull request introduces 1 alert when merging 41774c2 into fe061f4 - view on LGTM.com new alerts:
This project has automated code review enabled, but doesn't use the LGTM GitHub App. Migrate over by installing the app. Read about the benefits of migrating to GitHub Apps in the blog. Comment posted by LGTM.com |
@@ -763,6 +767,25 @@ void print_ip_address(char ip_address[]){ | |||
|
|||
|
|||
int main(){ | |||
int result = system("python ip_address.py 1"); | |||
int arraysize=14; | |||
char ip[arraysize]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is 14 always going to be large enough for the IP address? Maybe std::string could work better here
int result = system("python ip_address.py 1"); | ||
int arraysize=14; | ||
char ip[arraysize]; | ||
char current_char; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are you using all these local variables? If not, you can remove them
@@ -763,6 +767,25 @@ void print_ip_address(char ip_address[]){ | |||
|
|||
|
|||
int main(){ | |||
int result = system("python ip_address.py 1"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Does the 1
need to be passed in here?
No description provided.