Fix product_by_location with stock_skip_warehouse and no product_ids

issue3843
review5171002
(grafted from f2f79e388f07fede7be1273ad1e64477a78eaadf)

--HG--
branch : 2.4
extra : source : f2f79e388f07fede7be1273ad1e64477a78eaadf
extra : amend_source : c4f1c52585fc0b4c7511ba9aa50ead831432dd03
Prepare release 2.4.8

--HG--
branch : 2.4
Added tag 2.4.8 for changeset 394d58c25387

--HG--
branch : 2.4
Increase version number

--HG--
branch : 2.4