mirror of
				https://github.com/mborgerson/xemu.git
				synced 2025-10-30 04:31:19 +00:00 
			
		
		
		
	Address the comment added in commit 4629ed1e98
("qerror: Finally unused, clean up"), from 2015:
  /*
   * These macros will go away, please don't use
   * in new code, and do not add new ones!
   */
Mechanical transformation using:
  $ sed -i -e "s/QERR_INVALID_PARAMETER,/\"Invalid parameter '%s'\",/" \
    $(git grep -lw QERR_INVALID_PARAMETER)
Manually simplify qemu_opts_create(), and remove the macro definition
in include/qapi/qmp/qerror.h.
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Message-ID: <20240312141343.3168265-6-armbru@redhat.com>
		
	
			
		
			
				
	
	
		
			48 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
			
		
		
	
	
			48 lines
		
	
	
		
			1.1 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
| /*
 | |
|  * QError Module
 | |
|  *
 | |
|  * Copyright (C) 2009 Red Hat Inc.
 | |
|  *
 | |
|  * Authors:
 | |
|  *  Luiz Capitulino <lcapitulino@redhat.com>
 | |
|  *
 | |
|  * This work is licensed under the terms of the GNU LGPL, version 2.1 or later.
 | |
|  * See the COPYING.LIB file in the top-level directory.
 | |
|  */
 | |
| #ifndef QERROR_H
 | |
| #define QERROR_H
 | |
| 
 | |
| /*
 | |
|  * These macros will go away, please don't use in new code, and do not
 | |
|  * add new ones!
 | |
|  */
 | |
| 
 | |
| #define QERR_INVALID_PARAMETER_TYPE \
 | |
|     "Invalid parameter type for '%s', expected: %s"
 | |
| 
 | |
| #define QERR_INVALID_PARAMETER_VALUE \
 | |
|     "Parameter '%s' expects %s"
 | |
| 
 | |
| #define QERR_IO_ERROR \
 | |
|     "An IO error has occurred"
 | |
| 
 | |
| #define QERR_MIGRATION_ACTIVE \
 | |
|     "There's a migration process in progress"
 | |
| 
 | |
| #define QERR_MISSING_PARAMETER \
 | |
|     "Parameter '%s' is missing"
 | |
| 
 | |
| #define QERR_PROPERTY_VALUE_BAD \
 | |
|     "Property '%s.%s' doesn't take value '%s'"
 | |
| 
 | |
| #define QERR_PROPERTY_VALUE_OUT_OF_RANGE \
 | |
|     "Property %s.%s doesn't take value %" PRId64 " (minimum: %" PRId64 ", maximum: %" PRId64 ")"
 | |
| 
 | |
| #define QERR_QGA_COMMAND_FAILED \
 | |
|     "Guest agent command failed, error was '%s'"
 | |
| 
 | |
| #define QERR_UNSUPPORTED \
 | |
|     "this feature or command is not currently supported"
 | |
| 
 | |
| #endif /* QERROR_H */
 |