Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[UI] IPv4, IPv6 and TOR stats added to Information tab #930

Merged
merged 2 commits into from
Aug 6, 2016

Conversation

crowning-
Copy link

I think it's convenient to have this information inside the wallet instead from some suspicious external websites :-)

Looks like this:
ip_stats

@crowning- crowning- changed the title [UI] IPV4, IPv6 and TOR stats added to Information tab [UI] IPv4, IPv6 and TOR stats added to Information tab Aug 5, 2016
@UdjinM6
Copy link

UdjinM6 commented Aug 6, 2016

Like the idea but the implementation can be improved imo - all "id"s and functions are already in place, see:
https://github.com/dashpay/dash/blob/v0.12.1.x/src/netbase.h#L35
https://github.com/dashpay/dash/blob/v0.12.1.x/src/netbase.h#L63
https://github.com/dashpay/dash/blob/v0.12.1.x/src/netbase.h#L64
https://github.com/dashpay/dash/blob/v0.12.1.x/src/netbase.h#L78

{
case NODE_IPV4:
return nIPv4_nodes;
break;
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no need for break after return

@crowning-
Copy link
Author

crowning- commented Aug 6, 2016

Thanks a lot, I didn't know the constants are all there already. Having ALWAYS a break statement is IMO good practice, someone might change the code and forget to put them back in. No problem to delete them here as it's just one line of code anyway, though.

I'll check whether the compiler gives a warning when I move the last return statement. If not, I'll make it the default of the switch

@crowning-
Copy link
Author

Done.
Squashing the commits is done by @schinzelh if I remember correctly.

@schinzelh
Copy link

utACK aaa320e

Yep, will squash on merge :)

@UdjinM6
Copy link

UdjinM6 commented Aug 6, 2016

Nice, utACK aaa320e :)

@schinzelh schinzelh merged commit 072fd72 into dashpay:v0.12.1.x Aug 6, 2016
@UdjinM6 UdjinM6 mentioned this pull request Aug 12, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants