Related to (but neither caused nor fixed by): #46.
Filing because I noticed the issue by inspection, not from a particular known defect.
Basically, because of the gating to native.getProcessList, if one invocation is called with one set of flags, and then with another is made before the first returns, the second invocation will get results from the wrong flags. This could confuse code in cases where e.g. you requested memory info and occasionally do not receive it seemingly randomly.
Instead, there should probably be logic along the lines of:
- different queues for different sets of flags
- on completion of an invocation, callbacks run for all queues with fully-satisfied flags
- if there are queued requests for additional flags, re-run with those flags immediately
Or something like that. Or just always run with all the flags, unless there's a performance reason not to.
Related to (but neither caused nor fixed by): #46.
Filing because I noticed the issue by inspection, not from a particular known defect.
Basically, because of the gating to
native.getProcessList, if one invocation is called with one set of flags, and then with another is made before the first returns, the second invocation will get results from the wrong flags. This could confuse code in cases where e.g. you requested memory info and occasionally do not receive it seemingly randomly.Instead, there should probably be logic along the lines of:
Or something like that. Or just always run with all the flags, unless there's a performance reason not to.