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

Restarting the application leads to invalid object cache #1

Open
looki opened this issue Jun 26, 2016 · 0 comments
Open

Restarting the application leads to invalid object cache #1

looki opened this issue Jun 26, 2016 · 0 comments

Comments

@looki
Copy link

looki commented Jun 26, 2016

Hey,

There is a problem with the way the MMF interface caches object pointers (LPHO): it does not purge the cache when the application is restarted. This basically leads to mmf.newObject() returning garbage for the same object that worked fine before restarting the application.

I've added a simple hotfix for our needs by creating a new function in the mmf table that will simply reset the KEY_POOL_OBJECT table that we call at the beginning of the main script; I don't know how to properly implement this without the need for a manual function call. The MMFI doesn't seem to be aware of restarts etc., so it might need some interaction between the MMFI and the xlua dll?

EDIT: I guess another kind of hacky solution would be to keep track of the CRunFrame pointer or similar unique values, and updating cache entries that do not match the current value.

I do realize that you're not actively developing this project anymore, but I thought I'd let you know, maybe it is something you would like to fix :)

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