diff --git a/src/kits/package/FetchFileJob.cpp b/src/kits/package/FetchFileJob.cpp index 2ec38fcb04..6f53ca8647 100644 --- a/src/kits/package/FetchFileJob.cpp +++ b/src/kits/package/FetchFileJob.cpp @@ -90,6 +90,9 @@ FetchFileJob::Execute() BUrlRequest* request = BUrlProtocolRoster::MakeRequest(fFileURL.String(), this); + if (request == NULL) + return B_BAD_VALUE; + thread_id thread = request->Run(); wait_for_thread(thread, NULL);