Go to file
Jose M. Guisado dce0b0c1e3 context: fix assign_device
Fixes a bug where calling assign_device with readonly keyword parameter
raises exception stating it takes no keyword arguments.

Context_assign_device has positional and keyword arguments. Adds
flags METH_KEYWORDS in method declaration (see Context_methods).

Replaces format string in PyArg_ParseTupleAndKeywords from "s|p" to
"s|$p". Adds $ after |, meaning all later optional arguments are
also keyword only.
(See https://docs.python.org/3/c-api/arg.html#other-objects)

Empty names in the kwlist array correspond to positional arguments.

Replaces fname variable name with device for better readability.

Fixes 88c7374db2
("context: check self->cxt and rc in assign_device")
2023-01-10 10:15:24 +01:00
.gitignore Initial commit 2022-04-06 12:56:11 +02:00
COPYING Add COPYING and license headers 2022-04-07 17:03:34 +02:00
MANIFEST.in Add MANIFEST.in 2022-04-06 15:40:31 +02:00
context.c context: fix assign_device 2023-01-10 10:15:24 +01:00
fdisk.c fdisk: remove unuseful comment 2022-12-15 17:46:47 +01:00
fdisk.h context: delete unused label field 2022-12-20 16:18:31 +01:00
label.c fdisk: declare kwlist array static 2022-12-15 17:51:17 +01:00
partition.c fdisk: declare kwlist array static 2022-12-15 17:51:17 +01:00
parttype.c coding style: line breaks 2022-12-15 17:37:07 +01:00
setup.py release: bump to version 1.1 2022-12-20 16:38:40 +01:00