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

xOBSE 22.10beta causes console spam for Lovers with PK script xx0090ea #220

Closed
Hotdog3223 opened this issue Sep 14, 2023 · 9 comments
Closed
Labels

Comments

@Hotdog3223
Copy link

This is a script that just does a simple check to see if OBSE is actually running or not.

Deleting the script itself in xEdit stops the spam. Older versions of xOBSE did not have this spam problem.

@llde
Copy link
Owner

llde commented Sep 14, 2023

Revert. The beta has some issues.

@calebtt
Copy link
Contributor

calebtt commented Sep 14, 2023

What is it spamming?

@Hotdog3223
Copy link
Author

Hotdog3223 commented Sep 14, 2023

It just keeps spamming the script id & null, it doesn't actually have any impact on the mod's functionality but it spams the console with that over and over endlessly

@llde
Copy link
Owner

llde commented Sep 14, 2023

Yeah I think I mistook an hook for another in 5c31c42

BTW @calebtt Seems that there is an issue for 0d71ba4 that can cause corruption and exploding cosaves.

@llde
Copy link
Owner

llde commented Sep 14, 2023

@calebtt Seems that using std::array<char,dim>
instead of a direct array cause this corruption. Do you have any idea why?

EDIT: IT's actually a bit different:
SetElementString(arrayID, newKey, std::string(buffer.cbegin(), buffer.cend()));
if I create the std::string using an iterator ()either const cbegin/cend or normal begin/end) the resulting cosave is partially corrupted and explode in size.
If I create the string using the std::Array data() inner pointer then it's correct and with the right size (940KB (ok) vs 14 MB (wrong))
Do you have an idea on what's is going wrong? @calebtt
I tried to print the string content but they are equals

@llde
Copy link
Owner

llde commented Sep 15, 2023

Actually in this case it seems the script have an issue (maybe it wasn't recompiled properly?) as even in MessageLogger with 22.9 I have
2023/09/15 10:12:42 [005170B1] [WARNING] Unable to find function definition for command 0 in script 'xLoversCheckObse2QuestScript'.

Now the last beta have actually an issue where the message buffer wasn't saved properly or was corrupted, causing the message to be strange

@llde llde closed this as completed in 3ddc62c Sep 15, 2023
@calebtt
Copy link
Contributor

calebtt commented Sep 16, 2023

I'll try to look into that

@calebtt
Copy link
Contributor

calebtt commented Sep 16, 2023

@calebtt Seems that using std::array<char,dim> instead of a direct array cause this corruption. Do you have any idea why?

EDIT: IT's actually a bit different: SetElementString(arrayID, newKey, std::string(buffer.cbegin(), buffer.cend())); if I create the std::string using an iterator ()either const cbegin/cend or normal begin/end) the resulting cosave is partially corrupted and explode in size. If I create the string using the std::Array data() inner pointer then it's correct and with the right size (940KB (ok) vs 14 MB (wrong)) Do you have an idea on what's is going wrong? @calebtt I tried to print the string content but they are equals

iterators would iterate over the entire array, I think using .data works because you have it null padded after the string's contents. As long as you initialize the array to zero.

Oh I see we're actually setting a 0 value at the string's length.

@calebtt
Copy link
Contributor

calebtt commented Sep 16, 2023

Instead of the iterators I think it should be .data()

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants