Skip to content

Commit

Permalink
fix: set sigalarm for escape hanging
Browse files Browse the repository at this point in the history
  • Loading branch information
qwerty-theori committed Dec 16, 2024
1 parent 77356e2 commit 0590d53
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -600,12 +600,12 @@ int race_trigger(void *arg)
times[i] = t1-t0;
}

// for(int i=0; i<OBJS_PER_SLAB; i++)
// printf("%d: %d\n", i, times[i]);
for(int i=0; i<OBJS_PER_SLAB; i++)
printf("%d: %d\n", i, times[i]);

int inuse = -1, currv = 0;
for(int i=OBJS_PER_SLAB-1; i>=0; i--)
if(times[i] > 5500)
if(times[i] > 6000)
{
inuse = OBJS_PER_SLAB - i;
break;
Expand Down Expand Up @@ -787,7 +787,7 @@ void root(char *buf)

int main(int argc, void *argv[])
{

alarm(120);
if (argc > 1)
{
printf("triggered from core_pattern\n");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -806,6 +806,7 @@ int main(int argc, void *argv[])
exit(0);
}

alarm(120);
// PHYS_LO_32 = strtoll(argv[1], NULL, 0);
struct rlimit rlim = {
.rlim_cur = 4096,
Expand Down

0 comments on commit 0590d53

Please sign in to comment.