shared/shell: Return NULL if generator error occur

Explicitly returns NULL if asprintf() fails, since the asprintf(3)
man-page says that the contents of the first argument are undefined if
any error occurs.
1 file changed