Am 24.03.2020 um 08:14 hat Philippe Mathieu-Daudé geschrieben: > On 3/24/20 4:05 AM, Mansour Ahmadi wrote: > > Hi, > > > > Nullness of needs to be checked here: > > https://github.com/qemu/qemu/blob/c532b954d96f96d361ca31308f75f1b95bd4df76/block/commit.c#L221 > > > > pstrcpy(bs->exact_filename, sizeof(bs->exact_filename),...
Do you have a reproducer? It's not obvious to me how bs->backing could be NULL here. > > > > While it is done at 2 other locations: > > https://github.com/qemu/qemu/blob/c532b954d96f96d361ca31308f75f1b95bd4df76/block/backup-top.c#L113 > > https://github.com/qemu/qemu/blob/c532b954d96f96d361ca31308f75f1b95bd4df76/block/mirror.c#L1477 Commit 18775ff3269 made the change for mirror, however its commit message is terse and doesn't say anything about the scenario where it would happen. We also didn't add a test case for it. I would have expected that failure to add the backing file would immediately error out and not try to refresh the filename first. backup-top.c has the check from the beginning. I assume it just copied it from mirror. Vladimir, do you remember the details? Kevin
