提交 407f879a 编写于 作者: B Blue Swirl

scsi: fix incorrect ?: use

Fixes OpenBSD build.
Signed-off-by: NBlue Swirl <blauwirbel@gmail.com>
上级 d08d6f04
......@@ -346,7 +346,8 @@ static int scsi_disk_emulate_inquiry(SCSIRequest *req, uint8_t *outbuf)
case 0x80: /* Device serial number, optional */
{
const char *serial = req->dev->dinfo->serial ?: "0";
const char *serial = req->dev->dinfo->serial ?
req->dev->dinfo->serial : "0";
int l = strlen(serial);
if (l > req->cmd.xfer)
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册