Re: [PATCH 1/1] openvpn: add support to change interface name



Dan Williams <dcbw redhat com> on Wed, 2014/10/01 09:19:
On Tue, 2014-09-30 at 21:07 +0200, Christian Hesse wrote:
Christian Hesse <mail eworm de> on Mon, 2014/09/29 14:46:
By default interface name is 'tun' or 'tap' with an incrementing number
(tun0, tun1, ... or tap0, tap1, ...). By specifying 'Interface name' in
vpnc config you can change the name to something more descriptice.

The vpnc part has been merge with some changes. So questions arise:

* Do you want to update the UI file for GTK+ 3.4 and get an updated patch
for that?

I just did that and pushed it.  Perhaps you wanted to do it yourself? :)
But it's really tedious and I figured you didn't...

No, I did not. ;)

* Do you want the interface name widget on Advanced dialog? I suppose yes.

Yeah, lets do that, on the first tab page where stuff like ports and
tun/tap are.

Done.
Though this does not (yet) have a checkbox. Do we want that? Requires some
callback function then, no?

* Any other changes?

One other style change, when there's code like:

+               g_object_set (G_OBJECT (s_con),
+                               NM_SETTING_CONNECTION_INTERFACE_NAME,
str, NULL);

if it all fits on one line within about 100 characters, then let's put
it on one line.  If it's longer than that, then multi-line, but in that
case lets do some { } and align it like so (two places to do this...):

+       if (str && strlen (str)) {
+               g_object_set (G_OBJECT (s_con),
+                             NM_SETTING_CONNECTION_INTERFACE_NAME, str,
+                             NULL);
+       }

Sound OK?  Thanks!

Sure. I did break lines whenever I felt it was too long. And I made it "look
ok" in relation to the surrounding code. "Within about 100 characters" is not
that precise... ;)

I will reply with a new patch soon.
-- 
Schoene Gruesse
Chris
                         O< ascii ribbon campaign
                   stop html mail - www.asciiribbon.org

Attachment: signature.asc
Description: PGP signature



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]