pipe-loader: handle memory allocation failure