Slice Posted May 12, 2020 Share Posted May 12, 2020 1 minute ago, Matgen84 said: Why test binary release 5117! Because we want to know if there is compiler dependency. You compile your Clover and release Clover was compiled by me. 1 Link to comment Share on other sites More sharing options...
Pene Posted May 12, 2020 Share Posted May 12, 2020 Also make sure every time to delete the misc.png folder. Becasuse Clover will not delete it for you. The question is if it is recreated when you make a screeshot. 1. with your build 2. with our build Link to comment Share on other sites More sharing options...
Matgen84 Posted May 12, 2020 Share Posted May 12, 2020 (edited) 11 minutes ago, Slice said: Because we want to know if there is compiler dependency. You compile your Clover and release Clover was compiled by me. Thanks As @Pene says in a previous post (not the last): I delete misc folder Press F10 After restart, mount ESP: misc folder what recreated, without misc.png folder Do you want me to test Binaries Release 5117 anyway. Edited May 12, 2020 by Matgen84 Link to comment Share on other sites More sharing options...
Matgen84 Posted May 12, 2020 Share Posted May 12, 2020 Just now, Pene said: You are saying misc IS recreated or NOT recreated? I dont understand. misc folder is recreated (with my own build). Do you want me to test Binaries Release 5117 anyway. Link to comment Share on other sites More sharing options...
Pene Posted May 12, 2020 Share Posted May 12, 2020 Just now, Matgen84 said: misc folder is recreated (with my own build). Do you want me to test Binaries Release 5117 anyway. I still dont understand. misc is recreated or misc.png is recreated? misc should be recreated, but misc.png not. Link to comment Share on other sites More sharing options...
Matgen84 Posted May 12, 2020 Share Posted May 12, 2020 Just now, Pene said: I still dont understand. misc is recreated or misc.png is recreated? misc should be recreated, but misc.png not. I wrote misc folder is recreated. misc.png not. Can you answer to me: Do you want me to test Binaries Release 5117 anyway. Link to comment Share on other sites More sharing options...
Pene Posted May 12, 2020 Share Posted May 12, 2020 Just now, Matgen84 said: I wrote misc folder is recreated. misc.png not. Can you answer to me: Do you want me to test Binaries Release 5117 anyway. If misc.png is not recreated there is no sense to test anything else. But I dont understand when the problem was solved or what was it. 1 Link to comment Share on other sites More sharing options...
Matgen84 Posted May 12, 2020 Share Posted May 12, 2020 4 minutes ago, Pene said: If misc.png is not recreated there is no sense to test anything else. But I dont understand when the problem was solved or what was it. I too do not understand when the problem was resolved and where it was. It's strange. Thanks. Link to comment Share on other sites More sharing options...
Pene Posted May 12, 2020 Share Posted May 12, 2020 (edited) @Jief_Machak @Slice Well, the problem is NOT resolved. I figured out how to reproduce it, sort of, sometimes. It just doesn't happen always. Reproduced with standard 5117 CLOVERX64.efi compiled by Slice, in Qemu, without any special drivers or Fat.efi. To reproduce in Qemu, press F10 like 30 times, one every second or so, and this is the result: /Volumes/NO NAME/EFI/CLOVER/misc: total 16069 -rwxrwxrwx 1 pene staff 434777 May 12 09:36 screenshot0.png -rwxrwxrwx 1 pene staff 434777 May 12 09:36 screenshot1.png -rwxrwxrwx 1 pene staff 430375 May 12 09:37 screenshot10.png -rwxrwxrwx 1 pene staff 430375 May 12 09:37 screenshot11.png -rwxrwxrwx 1 pene staff 434777 May 12 09:37 screenshot12.png -rwxrwxrwx 1 pene staff 430375 May 12 09:37 screenshot13.png -rwxrwxrwx 1 pene staff 433949 May 12 09:38 screenshot14.png -rwxrwxrwx 1 pene staff 430375 May 12 09:38 screenshot15.png -rwxrwxrwx 1 pene staff 430375 May 12 09:38 screenshot16.png -rwxrwxrwx 1 pene staff 433523 May 12 09:38 screenshot17.png -rwxrwxrwx 1 pene staff 430945 May 12 09:38 screenshot18.png -rwxrwxrwx 1 pene staff 434777 May 12 09:36 screenshot2.png -rwxrwxrwx 1 pene staff 434777 May 12 09:37 screenshot3.png -rwxrwxrwx 1 pene staff 434777 May 12 09:37 screenshot4.png -rwxrwxrwx 1 pene staff 434777 May 12 09:37 screenshot5.png -rwxrwxrwx 1 pene staff 430945 May 12 09:37 screenshot6.png -rwxrwxrwx 1 pene staff 433523 May 12 09:37 screenshot7.png -rwxrwxrwx 1 pene staff 431642 May 12 09:37 screenshot8.png -rwxrwxrwx 1 pene staff 431766 May 12 09:37 screenshot9.png /Volumes/NO NAME/EFI/CLOVER/miscgመ竑: /Volumes/NO NAME/EFI/CLOVER/miscg℘竑: /Volumes/NO NAME/EFI/CLOVER/miscg崘竊: /Volumes/NO NAME/EFI/CLOVER/miscg栘竊: /Volumes/NO NAME/EFI/CLOVER/miscg瀘竊: /Volumes/NO NAME/EFI/CLOVER/miscgꄘ竉: /Volumes/NO NAME/EFI/CLOVER/miscgꈘ竈: /Volumes/NO NAME/EFI/CLOVER/miscg찘竟: /Volumes/NO NAME/EFI/CLOVER/miscg竑: And no, I am not Chinese, nor do I use any Chinese characters Edited May 12, 2020 by Pene 1 Link to comment Share on other sites More sharing options...
Slice Posted May 12, 2020 Share Posted May 12, 2020 Yes, I already told about chinese folders. Link to comment Share on other sites More sharing options...
Pene Posted May 12, 2020 Share Posted May 12, 2020 2 minutes ago, Slice said: Yes, I already told about chinese folders. Where? In what context? We must find what this is. Link to comment Share on other sites More sharing options...
Slice Posted May 12, 2020 Share Posted May 12, 2020 But only in QEMU. I never got the error on real hardware. Link to comment Share on other sites More sharing options...
Pene Posted May 12, 2020 Share Posted May 12, 2020 1 minute ago, Slice said: But only in QEMU. I never got the error on real hardware. As labyone and matgen had it on real hardware (not Chinese but it's probably the same) I consider this problem real. What you did to get the Chinese folders? 1 Link to comment Share on other sites More sharing options...
Slice Posted May 12, 2020 Share Posted May 12, 2020 Screenshot or Preboot.log. But it is not now, I just remember it was. It was before XString. The error is in egSaveFile. 2 Link to comment Share on other sites More sharing options...
vector sigma Posted May 12, 2020 Share Posted May 12, 2020 (edited) 1 hour ago, Slice said: Screenshot or Preboot.log. But it is not now, I just remember it was. It was before XString. The error is in egSaveFile. but this works, why? ignore, I saw your last commit. Edited May 12, 2020 by vector sigma Link to comment Share on other sites More sharing options...
LAbyOne Posted May 12, 2020 Share Posted May 12, 2020 @Jief_Machak @Slice @Pene Sorry guys, just woke up Tested new 5117 replacing again to original code in libscreen.cpp folder is nolonger created... Thanks 1 Link to comment Share on other sites More sharing options...
Jief_Machak Posted May 12, 2020 Share Posted May 12, 2020 A memory overlap in egSaveFile ? Let's refactor egSaveFile to use XStringW... I'll try to save a bit of time later in day. 1 Link to comment Share on other sites More sharing options...
vector sigma Posted May 12, 2020 Share Posted May 12, 2020 (edited) 5 hours ago, Jief_Machak said: I missed this post : 9 hours ago, vector sigma said: Sorry I felt asleep, tomorrow Jief probably will fix it. That should compile: XStringW Name = L"EFI\\CLOVER\\misc\\screenshot_test.png"_XSW; Status = egSaveFile(SelfRootDir, Name.wc_str(), FileData, FileDataLength); if (EFI_ERROR(Status)) { MsgLog("Make screenshot_test fail\n"); } That doesn't compile ??? Yes this work. Only I did not tested it as I wrote it by hand with the phone as i was in bad 9 hours ago , but that apparently wont compile: XStringW Name = L"EFI\\CLOVER\\misc\\screenshot_test.png"; For me the original code works well, not sure why LabyOne and Matgen84 had problems. Seeing chinese characters and truncations looks like concatenating strings fail due to a null termination not present or present twice? But only a supposition, why I proposed LabyOne to test an "hard coded” string like the above. EDIT I spoke for the past as looks like now everythings works for every one EDIT 2 Also copying code from this forum (even from the code box) it adds special and invisible characters which prevent the right compilation Lol. This should be fixed... Edited May 12, 2020 by vector sigma Link to comment Share on other sites More sharing options...
Pene Posted May 12, 2020 Share Posted May 12, 2020 (edited) 2 hours ago, Slice said: Screenshot or Preboot.log. But it is not now, I just remember it was. It was before XString. The error is in egSaveFile. Thanks, I just didn't think to look at egSaveFile. From some reason we were stuck at looking at the wrong place. Now I look at egSaveFile, and the error is kind of obvious. I corrected in last commit. No more Chinese characters or weird directories. All the rest with it happening / not happening was just coincidence. 1 hour ago, Jief_Machak said: Let's refactor egSaveFile to use XStringW... I'll try to save a bit of time later in day. Not an urgency anymore. As usual the problem was not related to your code The only one that actually was related from all weird bugs that appeared lately and I bugged you with was/is the self assignment. So take your time and not get too agglomerated because of us bugging you with all kind of unrelated things Edited May 12, 2020 by Pene 2 Link to comment Share on other sites More sharing options...
vector sigma Posted May 12, 2020 Share Posted May 12, 2020 (edited) 28 minutes ago, Pene said: From some reason we were stuck at looking at the wrong place. Now I look at egSaveFile, and the error is kind of obvious. I corrected in last commit. Slice already did it directly in the StrnCpy() function in the previous commit.. Edited May 12, 2020 by vector sigma Link to comment Share on other sites More sharing options...
Slice Posted May 12, 2020 Share Posted May 12, 2020 Yes, the same. 1 Link to comment Share on other sites More sharing options...
Pene Posted May 12, 2020 Share Posted May 12, 2020 (edited) 6 minutes ago, vector sigma said: Slice already did it directly in the StrnCpy() function in the previous commit.. Missed that, but I was still getting chinese after that commit. Or was it before? I don't know anymore. Anyway it's gone now. Edited May 12, 2020 by Pene 1 Link to comment Share on other sites More sharing options...
Slice Posted May 12, 2020 Share Posted May 12, 2020 I think Matgen84 tested with this commit. As not release. 4 hours ago, Matgen84 said: I wrote misc folder is recreated. misc.png not. Can you answer to me: Do you want me to test Binaries Release 5117 anyway. Link to comment Share on other sites More sharing options...
vector sigma Posted May 12, 2020 Share Posted May 12, 2020 39 minutes ago, Pene said: The only one that actually was related from all weird bugs that appeared lately and I bugged you with was/is the self assignment. So take your time and not get too agglomerated because of us bugging you with all kind of unrelated things right! XString works like sharm! Link to comment Share on other sites More sharing options...
Pene Posted May 12, 2020 Share Posted May 12, 2020 (edited) 6 minutes ago, Slice said: I think Matgen84 tested with this commit. As not release. But I'm not sure it's a good idea to do that in StrnCpy. Because that's against the standard implementation: http://www.cplusplus.com/reference/cstring/strncpy/ Sometimes, we may pass a buffer of specific size, and doing a *Destination = L'\0' at the end may write past that buffer. StrnCpy cannot know what size of buffer we have, only what we specified. That's why standard implementation does not include '\0' in this case. Edited May 12, 2020 by Pene Link to comment Share on other sites More sharing options...
Recommended Posts