[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Tinycc-devel] crash with -b
From: |
Yakov |
Subject: |
[Tinycc-devel] crash with -b |
Date: |
Mon, 5 Apr 2021 03:01:57 +0700 |
this coredumps with latest pull from mob if compiled with -b on ubuntu 20.
took me half a day to boil it down from my large program.
---- 8< ---------------------------------
#include <stdlib.h>
#include <stdio.h>
void mm(char *d, const char *s) {
d[0] = s[0];
}
int main(int argc, char**argv) {
char *b = "c";
char **a = malloc(sizeof(void*));
a[0] = malloc(1);
mm(a[0], b);
}
- [Tinycc-devel] crash with -b,
Yakov <=