Commit fa24eccbd2f4841feb768105e4418756bb0415f2

Fixed crash of listallmgr

* Do not crash while adding items to software list
* Do not hang if database does not exists
  (Makes listallmgr load the global software list again)
  
350350 msg(rsLoading);
351351 blst := TStringList.Create; //Create Blacklist
352352
353 p_debug('SUMode: ' + BoolToStr(sumode));
353 if sumode then
354 p_debug('SUMode: Yes')
355 else
356 p_debug('SUMode: No');
354357
355358 db := TSoftwareDB.Create;
356359 db.Load(sumode);
414414 xtmp := FindAllFiles('/usr/local/share/applications/', '*.desktop', true);
415415 for i := 0 to xtmp.Count - 1 do
416416 tmp.Add(xtmp[i]);
417
418{xtmp.Assign(FindAllFiles('/usr/share/games/applications/','*.desktop',true));
419for i:=0 to xtmp.Count-1 do tmp.Add(xtmp[i]); }
417 xtmp.Free;
420418 end
421419 else
422420 tmp := FindAllFiles(GetEnvironmentVariable('HOME') +
423421 '/.local/share/applications', '*.desktop', false);
424
425 xtmp.Free;
426422
427423 for i := 0 to tmp.Count - 1 do
428424 begin
  
168168 end;
169169 CreateTable;
170170 end;
171 Active := true;
172 //ApplyUpdates;
173 Open;
171174 end;
172 Active := true;
173 //ApplyUpdates;
174 Open;
175175 end;
176176 p_info(rsDBOpened);
177177end;
  
200200 Result := true;
201201 with MnFrm do
202202 begin
203 writeLn(obj^.IconName);
204203 currAppList.ItemFromAppInfo(obj^);
205204 end;
206205 Application.ProcessMessages;