http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59083

--- Comment #14 from Markus Trippelsdorf <octoploid at yandex dot com> ---
The 'kernel' case passes a NULL pointer to qsort:

 % < test.i
struct relocs {
  int *offset;
};
static struct relocs a;
void qsort(void *, int) __attribute__((__nonnull__));
void die(int *p1, ...) {}

void sort_relocs(struct relocs *p1) { qsort(p1->offset, 0); }

int main() {
  sort_relocs(&a);
  return 0;
}

Reply via email to