Bugzilla – Attachment 537297 Details for
Bug 807377
Problems with 2 identical DVD burners
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Forgot Password
[patch]
Fixes device recognition in case of same wwn or same serial/model
udisks2-identical_devices.patch (text/plain), 1.23 KB, created by
Paolo Roascio
on 2013-04-29 14:47:10 UTC
(
hide
)
Description:
Fixes device recognition in case of same wwn or same serial/model
Filename:
MIME Type:
Creator:
Paolo Roascio
Created:
2013-04-29 14:47:10 UTC
Size:
1.23 KB
patch
obsolete
>diff -Naur udisks-2.0.0.orig/src/udiskslinuxdriveobject.c udisks-2.0.0/src/udiskslinuxdriveobject.c >--- udisks-2.0.0.orig/src/udiskslinuxdriveobject.c 2012-07-10 14:24:37.000000000 +0200 >+++ udisks-2.0.0/src/udiskslinuxdriveobject.c 2013-04-28 20:42:34.000000000 +0200 >@@ -733,18 +733,23 @@ > const gchar *serial; > const gchar *wwn; > const gchar *path; >+ const gchar *model; > > g_return_val_if_fail (G_UDEV_IS_DEVICE (device), FALSE); > >- /* order of preference: WWN, serial, path */ >+ /* order of preference: WWN_serial, WWN, serial (!= model), path */ > serial = g_udev_device_get_property (device, "ID_SERIAL"); > wwn = g_udev_device_get_property (device, "ID_WWN_WITH_EXTENSION"); > path = g_udev_device_get_property (device, "ID_PATH"); >+ model = g_udev_device_get_property (device, "ID_MODEL"); > if (wwn != NULL && strlen (wwn) > 0 && !is_wwn_black_listed (wwn)) > { >- ret = g_strdup (wwn); >+ if (serial != NULL && strlen (serial) > 0) >+ ret = g_strdup_printf ("%s_%s", wwn, path); >+ else >+ ret = g_strdup (wwn); > } >- else if (serial != NULL && strlen (serial) > 0) >+ else if (serial != NULL && strlen (serial) > 0 && g_strcmp0 (serial, model) != 0) > { > ret = g_strdup (serial); > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
Actions:
View
|
Diff
Attachments on
bug 807377
: 537297