Skip to content

Data comments at function addresses cannot be edited from linear view #7938

@zznop

Description

@zznop

Bug Description:
If a data comment is created at an address and a function is created over top of that address then that data comment cannot be edited or deleted using the comment dialog with the ; hotkey in linear view. The comment dialog defaults to function comments at any address that contains a function, and data comments only when there isn't a function at that location.

Steps To Reproduce:
Please provide all steps required to reproduce the behavior:

  1. Navigate to a function
  2. Run bv.set_comment_at(here, "test")
  3. Hit ; to open the comment dialog
  4. Notice that the existing comment doesn't show up
  5. Enter a new comment
  6. Notice that now there is a data comment and a function comment at that location

Expected Behavior:
If there is a data comment already at the address, assume that the user wants to edit the existing data comment. If there is a function comment and a data comment at the same address default to opening the data comment, which allows the user to clear it before creating a function comment if they prefer.

Metadata

Metadata

Assignees

Labels

Effort: LowIssues require < 1 week of workImpact: LowIssue is a papercut or has a good, supported workaroundUI: LinearIssues with the Linear view

Type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions