// https://syzkaller.appspot.com/bug?id=4c915663aead5e3e4aa09f44247a0bed3808e569
// autogenerated by syzkaller (http://github.com/google/syzkaller)

#define _GNU_SOURCE
#include <endian.h>
#include <stdint.h>
#include <string.h>
#include <sys/syscall.h>
#include <unistd.h>

long r[1];
void loop()
{
  memset(r, -1, sizeof(r));
  syscall(__NR_mmap, 0x20000000, 0xfff000, 3, 0x32, -1, 0);
  r[0] = syscall(__NR_socket, 0x10, 3, 6);
  *(uint64_t*)0x20004000 = 0x20003ff4;
  *(uint32_t*)0x20004008 = 0xc;
  *(uint64_t*)0x20004010 = 0x20004ff0;
  *(uint64_t*)0x20004018 = 1;
  *(uint64_t*)0x20004020 = 0;
  *(uint64_t*)0x20004028 = 0;
  *(uint32_t*)0x20004030 = 0;
  *(uint16_t*)0x20003ff4 = 0x10;
  *(uint16_t*)0x20003ff6 = 0;
  *(uint32_t*)0x20003ff8 = 0;
  *(uint32_t*)0x20003ffc = 0;
  *(uint64_t*)0x20004ff0 = 0x20001dc8;
  *(uint64_t*)0x20004ff8 = 0x154;
  *(uint32_t*)0x20001dc8 = 0x154;
  *(uint16_t*)0x20001dcc = 0x1a;
  *(uint16_t*)0x20001dce = 1;
  *(uint32_t*)0x20001dd0 = 0;
  *(uint32_t*)0x20001dd4 = 0;
  *(uint8_t*)0x20001dd8 = 0;
  *(uint8_t*)0x20001dd9 = 0;
  *(uint8_t*)0x20001dda = 0;
  *(uint8_t*)0x20001ddb = 0;
  *(uint8_t*)0x20001ddc = 0;
  *(uint8_t*)0x20001ddd = 0;
  *(uint8_t*)0x20001dde = 0;
  *(uint8_t*)0x20001ddf = 0;
  *(uint8_t*)0x20001de0 = 0;
  *(uint8_t*)0x20001de1 = 0;
  *(uint8_t*)0x20001de2 = 0;
  *(uint8_t*)0x20001de3 = 0;
  *(uint8_t*)0x20001de4 = 0;
  *(uint8_t*)0x20001de5 = 0;
  *(uint8_t*)0x20001de6 = 0;
  *(uint8_t*)0x20001de7 = 0;
  *(uint64_t*)0x20001de8 = htobe64(0);
  *(uint64_t*)0x20001df0 = htobe64(1);
  *(uint16_t*)0x20001df8 = 0;
  *(uint16_t*)0x20001dfa = htobe16(0);
  *(uint16_t*)0x20001dfc = 0;
  *(uint16_t*)0x20001dfe = htobe16(0xa00e);
  *(uint16_t*)0x20001e00 = 0;
  *(uint8_t*)0x20001e02 = 0;
  *(uint8_t*)0x20001e03 = 0;
  *(uint8_t*)0x20001e04 = 0;
  *(uint32_t*)0x20001e08 = 0;
  *(uint32_t*)0x20001e0c = 0;
  *(uint32_t*)0x20001e10 = htobe32(0);
  *(uint32_t*)0x20001e20 = 0;
  *(uint8_t*)0x20001e24 = 0x33;
  *(uint32_t*)0x20001e28 = htobe32(0xe0000002);
  *(uint64_t*)0x20001e38 = 0;
  *(uint64_t*)0x20001e40 = 0;
  *(uint64_t*)0x20001e48 = 0;
  *(uint64_t*)0x20001e50 = 0;
  *(uint64_t*)0x20001e58 = 0;
  *(uint64_t*)0x20001e60 = 0;
  *(uint64_t*)0x20001e68 = 0;
  *(uint64_t*)0x20001e70 = 0;
  *(uint64_t*)0x20001e78 = 0;
  *(uint64_t*)0x20001e80 = 0;
  *(uint64_t*)0x20001e88 = 0;
  *(uint64_t*)0x20001e90 = 0;
  *(uint32_t*)0x20001e98 = 0;
  *(uint32_t*)0x20001e9c = 0;
  *(uint32_t*)0x20001ea0 = 0;
  *(uint32_t*)0x20001ea4 = 0x70bd26;
  *(uint32_t*)0x20001ea8 = 0;
  *(uint16_t*)0x20001eac = 0xa;
  *(uint8_t*)0x20001eae = 0;
  *(uint8_t*)0x20001eaf = 0;
  *(uint8_t*)0x20001eb0 = 0;
  *(uint16_t*)0x20001eb8 = 0x1c;
  *(uint16_t*)0x20001eba = 0x17;
  *(uint32_t*)0x20001ebc = 0xfffffe92;
  *(uint32_t*)0x20001ec0 = 0;
  *(uint32_t*)0x20001ec4 = 0;
  *(uint32_t*)0x20001ec8 = 0;
  *(uint32_t*)0x20001ecc = 0x70bd2a;
  *(uint32_t*)0x20001ed0 = 0;
  *(uint16_t*)0x20001ed4 = 0x48;
  *(uint16_t*)0x20001ed6 = 1;
  memcpy((void*)0x20001ed8,
         "\x64\x69\x67\x65\x73\x74\x5f\x6e\x75\x6c\x6c\x00\x00\x00\x00\x00\x00"
         "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"
         "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00"
         "\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00",
         64);
  *(uint32_t*)0x20001f18 = 0;
  syscall(__NR_sendmsg, r[0], 0x20004000, 0);
}

int main()
{
  loop();
  return 0;
}