**Describe the bug**
MonetDB server crashes in `ALGgroupby`.

**To Reproduce**
```sql
SELECT ( WITH x AS ( SELECT * FROM generate_series ( 32989 , 8100 ) EXCEPT SELECT * FROM generate_series ( 44 , 3 ) ) SELECT CASE WHEN NULL IN ( 69 , MAX ( CASE WHEN 97 THEN 66 END ) OVER ( ) + ( SELECT COUNT ( * ) ) ) THEN 41 END FROM x );
```

**Backtrace of the Crash**
```c
#0 0x7fc9d896505c (ALGgroupby+0xec)
#1 0x7fc9d87b76e9 (runMALsequence+0x17c9)
#2 0x7fc9d87bc293 (DFLOWworker+0x4a3)
#3 0x7fc9d973eb38 (thread_starter+0x318)
#4 0x7fc9d814f609 (start_thread+0xd9)
#5 0x7fc9d8072353 (clone+0x43)
```

**Software versions**
 - MonetDB version number: v11.49.1 (Dec2023)
 - OS and version: Ubuntu 20.04
 - From docker image monetdb/monetdb:Dec2023 (or monetdb/dev-builds:default)

An example of steps to reproduce in docker container (**write the poc into /tmp/test.sql first**):
```bash
docker container rm monetdb_test -f
docker run -e MDB_DB_ADMIN_PASS=monetdb --name monetdb_test -itd monetdb/monetdb:Dec2023
docker exec monetdb_test bash -c 'echo -n -e "user=monetdb\npassword=monetdb\n" > /root/.monetdb'

sleep 10
cat /tmp/test.sql | timeout 5s docker exec -i monetdb_test mclient monetdb     # run test case

if docker exec monetdb_test bash -c "grep '[m]server5' /proc/*/cmdline -lR"; then
    echo "[INFO] Server normal."
else
    echo "[CRASH] Mserver5 process does NOT exist."
fi
```

It can also be reproduced on the docker image `monetdb/dev-builds:default`.

**Issue labeling**
bug
MonetDB server crashes in `ALGgroupby`
This is a GitHub Issue
repo:MonetDB
owner:MonetDB
Title : MonetDB server crashes in `ALGgroupby`
Issue date:

--- start body ---
**Describe the bug**
MonetDB server crashes in `ALGgroupby`.

**To Reproduce**
```sql
SELECT ( WITH x AS ( SELECT * FROM generate_series ( 32989 , 8100 ) EXCEPT SELECT * FROM generate_series ( 44 , 3 ) ) SELECT CASE WHEN NULL IN ( 69 , MAX ( CASE WHEN 97 THEN 66 END ) OVER ( ) + ( SELECT COUNT ( * ) ) ) THEN 41 END FROM x );
```

**Backtrace of the Crash**
```c
#0 0x7fc9d896505c (ALGgroupby+0xec)
#1 0x7fc9d87b76e9 (runMALsequence+0x17c9)
#2 0x7fc9d87bc293 (DFLOWworker+0x4a3)
#3 0x7fc9d973eb38 (thread_starter+0x318)
#4 0x7fc9d814f609 (start_thread+0xd9)
#5 0x7fc9d8072353 (clone+0x43)
```

**Software versions**
 - MonetDB version number: v11.49.1 (Dec2023)
 - OS and version: Ubuntu 20.04
 - From docker image monetdb/monetdb:Dec2023 (or monetdb/dev-builds:default)

An example of steps to reproduce in docker container (**write the poc into /tmp/test.sql first**):
```bash
docker container rm monetdb_test -f
docker run -e MDB_DB_ADMIN_PASS=monetdb --name monetdb_test -itd monetdb/monetdb:Dec2023
docker exec monetdb_test bash -c 'echo -n -e "user=monetdb\npassword=monetdb\n" > /root/.monetdb'

sleep 10
cat /tmp/test.sql | timeout 5s docker exec -i monetdb_test mclient monetdb     # run test case

if docker exec monetdb_test bash -c "grep '[m]server5' /proc/*/cmdline -lR"; then
    echo "[INFO] Server normal."
else
    echo "[CRASH] Mserver5 process does NOT exist."
fi
```

It can also be reproduced on the docker image `monetdb/dev-builds:default`.

**Issue labeling**
bug
--- end body ---
