fix(desk): ring_push/ring_pop 漏拷 style 字段
根因:两个环函数是**逐字段拷贝**(type/win/pid/a/b/c/d + title),新增 DeskMsg.style 时没有同步补上。于是 app 侧正确写入 _msg.style(IR 已核对:store 到字段 7),但入队时被丢弃;explorer 读到的永远是共享槽里的残留 0 —— 日志表现为五个 CREATE 全 style=0,而 app 侧 [vpui] set_style NZ / geometry style!=0 完全正常。补上 push/pop 两侧的 style 拷贝。
This commit is contained in:
1 parent
a60c51076a
commit
384ab6e75f
1 file changed
+2
@@ -158,6 +158,7 @@ def ring_push(ctrl_off: uint64, msg: DeskMsg) -> int:
|
||||
slot.b = msg.b
|
||||
slot.c = msg.c
|
||||
slot.d = msg.d
|
||||
slot.style = msg.style
|
||||
string.memcpy(&slot.title, &msg.title, uint64(DESK_TITLE_MAX))
|
||||
c.tail = nxt # 最后写 tail:读者以 tail 为"有货"的标志
|
||||
return 0
|
||||
@@ -175,6 +176,7 @@ def ring_pop(ctrl_off: uint64, out: DeskMsg*) -> int:
|
||||
out.b = slot.b
|
||||
out.c = slot.c
|
||||
out.d = slot.d
|
||||
out.style = slot.style
|
||||
string.memcpy(&out.title, &slot.title, uint64(DESK_TITLE_MAX))
|
||||
c.head = (c.head + uint32(1)) % c.size
|
||||
return 1
|
||||
|
||||
Reference in new issue
Block a user