Skip to content

Commit

Permalink
matched READ_CHECKED(ctx, cont);
Browse files Browse the repository at this point in the history
  • Loading branch information
tomvita committed Sep 22, 2020
1 parent 0e99770 commit e0a7a9b
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 8 deletions.
Binary file modified server/source/noexs/exefs.nsp
Binary file not shown.
2 changes: 1 addition & 1 deletion server/source/noexs/include/gecko.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

#define VER_MAJOR (1)
#define VER_MINOR (1)
#define VER_PATCH (141)
#define VER_PATCH (142)

#define GECKO_BUFFER_SIZE (2048 * 32)
#define GECKO_BUFFER_SIZE2 (2048 * 4)
Expand Down
Binary file modified server/source/noexs/noexs.nso
Binary file not shown.
Binary file modified server/source/noexs/noexs.nsp
Binary file not shown.
15 changes: 8 additions & 7 deletions server/source/noexs/source/commands.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ static Result process(Gecko::Context &ctx, u64 m_start, u64 m_end) {
//
WRITE_CHECKED(ctx, count);
WRITE_BUFFER_CHECKED(ctx, outbuffer, count);
READ_CHECKED(ctx,cont); if (!cont) {WRITE_CHECKED(ctx, 0); return USER_ABORT;}
READ_CHECKED(ctx,cont); if (!cont) {WRITE_CHECKED(ctx, 0);READ_CHECKED(ctx, cont); return USER_ABORT;}
out_index = 0;
}
}
Expand All @@ -508,9 +508,11 @@ static Result process(Gecko::Context &ctx, u64 m_start, u64 m_end) {
//
WRITE_CHECKED(ctx, count);
WRITE_BUFFER_CHECKED(ctx, outbuffer, count);
READ_CHECKED(ctx, cont);
out_index = 0;
}
WRITE_CHECKED(ctx, 0);
READ_CHECKED(ctx, cont);
return rc;
}

Expand Down Expand Up @@ -611,11 +613,7 @@ static Result processlocal(Gecko::Context &ctx, u64 m_start, u64 m_end, u64 m_va
//
WRITE_CHECKED(ctx, count);
WRITE_BUFFER_CHECKED(ctx, outbuffer, count);
READ_CHECKED(ctx, cont);
if (!cont) {
WRITE_CHECKED(ctx, 0);
return USER_ABORT;
}
READ_CHECKED(ctx,cont); if (!cont) {WRITE_CHECKED(ctx, 0);READ_CHECKED(ctx, cont); return USER_ABORT;}
out_index = 0;
}
}
Expand All @@ -638,9 +636,11 @@ static Result processlocal(Gecko::Context &ctx, u64 m_start, u64 m_end, u64 m_va
//
WRITE_CHECKED(ctx, count);
WRITE_BUFFER_CHECKED(ctx, outbuffer, count);
READ_CHECKED(ctx, cont);
out_index = 0;
}
WRITE_CHECKED(ctx, 0);
READ_CHECKED(ctx, cont);
return rc;
}

Expand Down Expand Up @@ -717,11 +717,12 @@ static Result _getbookmark(Gecko::Context& ctx){
printf("count = %d\n", count);
WRITE_CHECKED(ctx, count);
WRITE_BUFFER_CHECKED(ctx, outbuffer, count);
READ_CHECKED(ctx,cont); if (!cont) {WRITE_CHECKED(ctx, 0);fclose(g_memdumpFile); return USER_ABORT;}
READ_CHECKED(ctx,cont); if (!cont) {WRITE_CHECKED(ctx, 0);READ_CHECKED(ctx, cont);fclose(g_memdumpFile); return USER_ABORT;}
index += len;
size -= len;
}
WRITE_CHECKED(ctx, 0);
READ_CHECKED(ctx, cont);
fclose(g_memdumpFile);
return 0;
}
Expand Down

0 comments on commit e0a7a9b

Please sign in to comment.