New Section Does Not Appear After Creation Unless Save and Reopen Database
Version and Platform (required):
- Binary Ninja Version: 5.3.8657-dev Ultimate, a792480c
- OS: macos
- OS Version: 15.7
- CPU Architecture: arm64
Bug Description: If I create a new section in a new memory region, the new section does not appear in the disassembly view. To see it, you must save the database and open it again. After that, the section is visible in all places you would expect it.
Steps To Reproduce:
- Open this database:
quadratic galaxy rushes bidirectionally - Open Memory Map
- Right click -> Add Memory Region...
- Set Source: File Backed Region
- Set Name:
unpacked - Set Start:
0x440000 - Select File:
focused autumn marks infinitely - Check Flags: RWX
- Open Linear Disassembly View
- Turn off Single Function View
- Navigate to
0x441000 - In the Memory Map, right click in Sections -> Add Section...
- Set Name:
unpacked.text - Set Start:
0x441000 - Set Length:
0x18000 - Set Semantics: Read-only code
- Click OK
- Look at Disassembly View and note that the section has not appeared.
- Save database
- Close database
- Open database
- Note that you can now see the new section.
Expected Behavior: Section should appear immediately after creation. You should not need to save, close, and open the database to see it.
Screenshots: Create region:
Linear Disassembly View Before section created:
Add section:
Linear Disassembly View After section created:
Linear Disassembly View After save and reopen:
Additional problem, probably related: if you undo, the undo does nothing until after, again save, close, open.
Before undo:
After (look at history and then see that the section is still there in the view: