qemu-e2k/qom
Markus Armbruster 3f7febc937 qom: Improve error messages when property has no getter or setter
When you try to set a property that has no setter, the error message
blames "insufficient permission":

    $ qemu-system-x86_64 -S -display none -nodefaults -monitor stdio
    QEMU 7.1.50 monitor - type 'help' for more information
    (qemu) qom-set /machine type q35
    Error: Insufficient permission to perform this operation

This implies it could work with "sufficient permission".  It can't.
Change the error message to:

    Error: Property 'pc-i440fx-7.2-machine.type' is not writable

Do the same for getting a property that has no getter.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-Id: <20221012153801.2604340-2-armbru@redhat.com>
Reviewed-by: David Hildenbrand <david@redhat.com>
2022-10-27 07:54:45 +02:00
..
container.c
meson.build qom: Move the creation of the library to the main meson.build 2020-10-12 11:50:20 -04:00
object_interfaces.c include: add qemu/keyval.h 2022-04-21 17:03:51 +04:00
object.c qom: Improve error messages when property has no getter or setter 2022-10-27 07:54:45 +02:00
qom-hmp-cmds.c qobject: Change qobject_to_json()'s value to GString 2020-12-19 10:38:43 +01:00
qom-qmp-cmds.c Use g_new() & friends where that makes obvious sense 2022-03-21 15:44:44 +01:00
qom-qobject.c error: Eliminate error_propagate() manually 2020-07-10 15:18:08 +02:00
trace-events docs: fix references to docs/devel/tracing.rst 2021-06-02 06:51:09 +02:00
trace.h trace: switch position of headers to what Meson requires 2020-08-21 06:18:24 -04:00