Fixed segfault if gradient has no stops