Skip to content

Commit

Permalink
Merge pull request #70 from StarDustCFW/master
Browse files Browse the repository at this point in the history
Fix  Crash
  • Loading branch information
darkxex authored Aug 23, 2021
2 parents db591d8 + 2fdf967 commit 6d82771
Show file tree
Hide file tree
Showing 7 changed files with 10 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ include $(DEVKITPRO)/libnx/switch_rules
#---------------------------------------------------------------------------------
VERSION_MAJOR := 2
VERSION_MINOR := 1
VERSION_MICRO := 1
VERSION_MICRO := 2

APP_TITLE := RipJKAnime NX
APP_AUTHOR := AngelXex
Expand Down
Binary file modified out/RipJKAnime NX[05B9DB505ABBE000][v0].nsp
Binary file not shown.
Binary file not shown.
Binary file modified out/RipJKAnime_NX.nro
Binary file not shown.
Binary file modified out/RipJKForwader[05B9DB505ABBE000][v0].nsp
Binary file not shown.
8 changes: 6 additions & 2 deletions source/JKanime.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -370,8 +370,10 @@ int MKfavimgfix(bool images){
if(BD["arrays"]["favorites"]["images"].empty() || BD["arrays"]["favorites"]["link"].empty()){
printf("# Get fav list\n");
getFavorite();
printf("# Goted fav list\n");
}
porcentajebufferFF = BD["arrays"]["favorites"]["link"].size();
if (porcentajebufferFF <= 0) return 0;

if (images) {
CheckImgVector(BD["arrays"]["favorites"]["images"],porcentajebufferF);
Expand Down Expand Up @@ -593,8 +595,10 @@ void addFavorite(std::string text) {
*/
}
void getFavorite() {
BD["arrays"]["favorites"]["link"].clear();
BD["arrays"]["favorites"]["images"].clear();
if(!BD["arrays"]["favorites"].empty()){
BD["arrays"]["favorites"]["link"].clear();
BD["arrays"]["favorites"]["images"].clear();
}
std::string temp;
std::ifstream file(rootdirectory+"favoritos.txt");
std::string str;
Expand Down
5 changes: 3 additions & 2 deletions source/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,6 @@ int main(int argc, char **argv)
SDL_Thread* searchthread = NULL;
SDL_Thread* downloadthread = NULL;

//Set main Thread get images and descriptions
prothread = SDL_CreateThread(refrescarpro, "prothread", (void*)NULL);

//set custom music
GOD.intA();//init the SDL
Expand Down Expand Up @@ -147,6 +145,9 @@ int main(int argc, char **argv)
}

try{
//Set main Thread get images and descriptions
prothread = SDL_CreateThread(refrescarpro, "prothread", (void*)NULL);

//While application is running
while (!quit)
{
Expand Down

0 comments on commit 6d82771

Please sign in to comment.