only the entry from the server's list of drivers.
</para></listitem></varlistentry>
- <varlistentry><term>deldriverex <driver> [architecture] [version]
- </term><listitem><para>Delete the specified printer driver including driver files.
- You can limit this action to a specific architecture and a specific version.
- If no architecure is given, all driver files of that driver will be deleted.
+ <varlistentry><term>deldriverex <driver> [architecture] [version] [flags]
+ </term><listitem><para>Delete the specified printer driver and optionally files
+ associated with the driver.
+ You can limit this action to a specific architecture and a specific version.
+ If no architecure is given, all driver files of that driver will be deleted.
+ <parameter>flags</parameter> correspond to numeric DPD_* values, i.e. a value
+ of 3 requests (DPD_DELETE_UNUSED_FILES | DPD_DELETE_SPECIFIC_VERSION).
</para></listitem></varlistentry>
<varlistentry><term>enumdata</term><listitem><para>Enumerate all
uint32_t delete_flags = 0;
/* parse the command arguments */
- if (argc < 2 || argc > 4) {
- printf ("Usage: %s <driver> [arch] [version]\n", argv[0]);
+ if (argc < 2 || argc > 5) {
+ printf("Usage: %s <driver> [arch] [version] [flags]\n", argv[0]);
return WERR_OK;
}
if (argc >= 3)
arch = argv[2];
- if (argc == 4)
- vers = atoi (argv[3]);
-
- if (vers >= 0) {
+ if (argc >= 4) {
+ vers = atoi(argv[3]);
delete_flags |= DPD_DELETE_SPECIFIC_VERSION;
}
+ if (argc == 5)
+ delete_flags = atoi(argv[4]);
/* delete the driver for all architectures */
for (i=0; archi_table[i].long_archi; i++) {
- if (arch && !strequal( archi_table[i].long_archi, arch))
+ if (arch && !strequal(archi_table[i].long_archi, arch))
continue;
if (vers >= 0 && archi_table[i].version != vers)