1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123 | diff -Nru netcfg-1.135ubuntu4.1/debian/changelog netcfg-1.135ubuntu4.2/debian/changelog
--- netcfg-1.135ubuntu4.1/debian/changelog 2016-05-19 11:34:16.000000000 +0100
+++ netcfg-1.135ubuntu4.2/debian/changelog 2017-01-18 11:46:10.000000000 +0000
@@ -1,3 +1,16 @@
+netcfg (1.135ubuntu4.2) xenial; urgency=medium
+
+ * Do now show an empty option 4 when using netcfg, without a wifi-card,
+ and when automatic configuration fails. This is achieved by
+ substituting all choices into the question, from two internal select
+ templates of identical options but wifireconf one. This resolves UX
+ bug without changing translation strings or fuzzing any of the
+ existing translations. LP: #1558271
+ * Also use short stable systemd-udev names to discover descriptions for
+ the network interfaces. LP: #1572620
+
+ -- Dimitri John Ledkov <xnox@ubuntu.com> Wed, 18 Jan 2017 11:45:36 +0000
+
netcfg (1.135ubuntu4.1) xenial; urgency=medium
* With vlan connection type, finish-install.d would decide to purge
diff -Nru netcfg-1.135ubuntu4.1/debian/netcfg-common.templates netcfg-1.135ubuntu4.2/debian/netcfg-common.templates
--- netcfg-1.135ubuntu4.1/debian/netcfg-common.templates 2016-04-20 12:24:19.000000000 +0100
+++ netcfg-1.135ubuntu4.2/debian/netcfg-common.templates 2017-01-18 11:45:34.000000000 +0000
@@ -285,6 +285,21 @@
# :sl2:
_Description: Ethernet
+Template: netcfg/internal-enc
+Type: text
+# :sl2:
+_Description: Ethernet CCW bus
+
+Template: netcfg/internal-enP
+Type: text
+# :sl2:
+_Description: Ethernet PCI
+
+Template: netcfg/internal-enp
+Type: text
+# :sl2:
+_Description: Ethernet PCI
+
Template: netcfg/internal-tr
Type: text
# :sl2:
diff -Nru netcfg-1.135ubuntu4.1/debian/netcfg-dhcp.templates netcfg-1.135ubuntu4.2/debian/netcfg-dhcp.templates
--- netcfg-1.135ubuntu4.1/debian/netcfg-dhcp.templates 2016-04-06 19:34:51.000000000 +0100
+++ netcfg-1.135ubuntu4.2/debian/netcfg-dhcp.templates 2017-01-18 11:45:34.000000000 +0000
@@ -33,11 +33,8 @@
Template: netcfg/dhcp_options
Type: select
# :sl1:
-# Note to translators : Please keep your translation
-# below a 65 columns limit (which means 65 characters
-# in single-byte languages)
-#flag:translate!:4
-__Choices: Retry network autoconfiguration, Retry network autoconfiguration with a DHCP hostname, Configure network manually, ${wifireconf}, Do not configure the network at this time
+#flag:translate!:1
+__Choices: ${choices}
Default: Configure network manually
# :sl1:
_Description: Network configuration method:
@@ -68,10 +65,18 @@
If you are unsure, you should not continue without a default route:
contact your local network administrator about this problem.
+Template: netcfg/internal-nowifi
+Type: select
+# :sl1:
+__Choices: Retry network autoconfiguration, Retry network autoconfiguration with a DHCP hostname, Configure network manually, Do not configure the network at this time
+
Template: netcfg/internal-wifireconf
-Type: text
+Type: select
# :sl1:
-_Description: Reconfigure the wireless network
+# Note to translators : Please keep your translation
+# below a 65 columns limit (which means 65 characters
+# in single-byte languages)
+__Choices: Retry network autoconfiguration, Retry network autoconfiguration with a DHCP hostname, Configure network manually, Reconfigure the wireless network, Do not configure the network at this time
Template: netcfg/dhcp_timeout
Type: string
diff -Nru netcfg-1.135ubuntu4.1/dhcp.c netcfg-1.135ubuntu4.2/dhcp.c
--- netcfg-1.135ubuntu4.1/dhcp.c 2016-04-20 12:23:15.000000000 +0100
+++ netcfg-1.135ubuntu4.2/dhcp.c 2017-01-18 11:45:34.000000000 +0000
@@ -344,12 +344,11 @@
int ask_dhcp_options (struct debconfclient *client, const char *if_name)
{
- if (is_wireless_iface(if_name)) {
- debconf_metaget(client, "netcfg/internal-wifireconf", "description");
- debconf_subst(client, "netcfg/dhcp_options", "wifireconf", client->value);
- }
+ if (is_wireless_iface(if_name))
+ debconf_metaget(client, "netcfg/internal-wifireconf", "Choices");
else /* blank from last time */
- debconf_subst(client, "netcfg/dhcp_options", "wifireconf", "");
+ debconf_metaget(client, "netcfg/internal-nowifi", "Choices");
+ debconf_subst(client, "netcfg/dhcp_options", "choices", client->value);
/* critical, we don't want to enter a loop */
debconf_input(client, "critical", "netcfg/dhcp_options");
diff -Nru netcfg-1.135ubuntu4.1/netcfg-common.c netcfg-1.135ubuntu4.2/netcfg-common.c
--- netcfg-1.135ubuntu4.1/netcfg-common.c 2016-04-20 12:23:15.000000000 +0100
+++ netcfg-1.135ubuntu4.2/netcfg-common.c 2017-01-18 11:45:34.000000000 +0000
@@ -564,6 +564,16 @@
CMD_SUCCESS && client->value != NULL) {
return strdup(client->value);
}
+ /* If using systemd-udevd stable names try that as well
+ Those have two character prefix, then one character for
+ subtype. */
+ if (strlen(template) > 19) {
+ template[19] = '\0';
+ if (debconf_metaget(client, template, "description") ==
+ CMD_SUCCESS && client->value != NULL) {
+ return strdup(client->value);
+ }
+ }
} else {
strcpy(template, "netcfg/internal-wifi");
debconf_metaget(client, template, "description");
|