WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Conversation

@amibranch
Copy link

@amibranch amibranch commented Nov 14, 2025

The underlying functionality makes it possible to switch a certain memory in Cutter to data (via the shortcut d). This functionality is comparable to other similar products. The functionality already existed in cutter. Unfortunately it was broken due to two problems:

  • The underlying action was not added to a widget - this is now fixed, by adding it to the setToDataMenu - like other related actions
  • If the underlying meta was not prevously data, it simply just ignored the action, as the size of the data returned uninitilialized memory. This is now fixed. Returning -1 from CutterCore::sizeofDataMeta indicates that the Meta at the address is currently no data.

This change fixes the problem

Your checklist for this pull request

Detailed description

Please note: the problem was observed, by using Arch Linux with Sway and qt6-base version 6.10.0. If the described problem is not observed on other systems: please provide this as feedback so the change can be limited!

Test plan (required)

Load a binary and simply press "d"-key (multiple times) at a memory-location that was not data before.

Closing issues

@notxvilka notxvilka requested a review from karliss November 14, 2025 16:43
@amibranch amibranch force-pushed the fix_set_to_data_shortcut branch 2 times, most recently from 1ee042c to 6187d45 Compare November 14, 2025 18:52
The underlying functionality makes it possible to switch a certain
memory in Cutters Disassembly-view to data (via the shortcut `d`). This
functionality is comparable to other similar products. The functionality
already existed in cutter. Unfortunately it was broken due to two
problems:
* The underlying action was not added to a widget - this is now fixed,
  by adding it to the `setToDataMenu` - like other related actions
* If the underlying meta was not prevously data, it simply just ignored
  the action, as the size of the data returned uninitilialized memory.
  This is now fixed. Returning 0 from `CutterCore::sizeofDataMeta`
  by default indicating that the Meta at the address is not data.
@amibranch amibranch force-pushed the fix_set_to_data_shortcut branch from 6187d45 to 333e035 Compare November 16, 2025 08:30
@amibranch amibranch requested a review from notxvilka November 16, 2025 19:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants