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

Can't reset a shared counter #156

Open
hommeabeil opened this issue Feb 8, 2018 · 0 comments
Open

Can't reset a shared counter #156

hommeabeil opened this issue Feb 8, 2018 · 0 comments

Comments

@hommeabeil
Copy link

It seems to be impossible to reset a shared counter with the function gproc:reset_counter/1. By looking at the source code, you seems to used the self() in the ETS key. In the case of shared counter I do not think the self() is part of the key...

If I do the same operation as in the module (read and write) then everything works as expected.

This is the relevent stack trace information:

   [{ets,lookup_element,[gproc,{{c,l,time_used},<0.1144.0>},3],[]},
    {gproc,reset_counter1,1,
        [{file,
             "c:/dev/Genetec.Plugins.Snmp.Gateway/_build/default/lib/gproc/src/gproc.erl"},
         {line,1828}]},
    {gproc,reset_counter,1,
        [{file,
             "c:/dev/Genetec.Plugins.Snmp.Gateway/_build/default/lib/gproc/src/gproc.erl"},
         {line,1819}]},```
@hommeabeil hommeabeil changed the title Can reset a shared counter Can't reset a shared counter Feb 8, 2018
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

No branches or pull requests

1 participant