X-Git-Url: http://nsz.repo.hu/git/?a=blobdiff_plain;f=ir%2Fstat%2Fpattern.c;h=47ff364dcc3f482292b1985c5399f9596fe7e065;hb=2af4a97900b435e35d7c20350604e3863aff2b4c;hp=cc7dbabe30c0a58986f3f7cedffe891af13308db;hpb=bb9f2e36362333c6635b89f5258171b06c786608;p=libfirm diff --git a/ir/stat/pattern.c b/ir/stat/pattern.c index cc7dbabe3..47ff364dc 100644 --- a/ir/stat/pattern.c +++ b/ir/stat/pattern.c @@ -648,9 +648,7 @@ static pattern_entry_t *pattern_get_entry(CODE_BUFFER *buf, pset *set) { unsigned len = buf_lenght(buf); unsigned hash; - key = obstack_alloc(&status->obst, offsetof(pattern_entry_t, buf) + len); - assert(key); - + key = OALLOCF(&status->obst, pattern_entry_t, buf, len); key->len = len; memcpy(key->buf, buf_content(buf), len);