* Extracted error message for the sake of legibility
@ 2024-07-25 20:42 Ariel Otilibili
2024-07-25 20:42 ` [PATCH] " Ariel Otilibili
[not found] ` <20240801094932.4502-1-otilibil@eurecom.fr>
0 siblings, 2 replies; 3+ messages in thread
From: Ariel Otilibili @ 2024-07-25 20:42 UTC (permalink / raw)
To: wireguard; +Cc: Ariel Otilibili
Hello,
I have been using WireGuard for some time; it does ease the configuration of
VPNs. This is my first patch to the list, I asked to be subscribed; please
confirm me it is the case.
I would like to improve my C programming skills; your feedback will be much
appreciated.
Ariel
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH] Extracted error message for the sake of legibility
2024-07-25 20:42 Extracted error message for the sake of legibility Ariel Otilibili
@ 2024-07-25 20:42 ` Ariel Otilibili
[not found] ` <20240801094932.4502-1-otilibil@eurecom.fr>
1 sibling, 0 replies; 3+ messages in thread
From: Ariel Otilibili @ 2024-07-25 20:42 UTC (permalink / raw)
To: wireguard; +Cc: Ariel Otilibili
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
---
src/set.c | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
diff --git a/src/set.c b/src/set.c
index 75560fd..b2fbd54 100644
--- a/src/set.c
+++ b/src/set.c
@@ -16,9 +16,19 @@ int set_main(int argc, const char *argv[])
{
struct wgdevice *device = NULL;
int ret = 1;
+ const char *error_message = "Usage: %s %s <interface>"
+ " [listen-port <port>]"
+ " [fwmark <mark>]"
+ " [private-key <file path>]"
+ " [peer <base64 public key> [remove]"
+ " [preshared-key <file path>]"
+ " [endpoint <ip>:<port>]"
+ " [persistent-keepalive <interval seconds>]"
+ " [allowed-ips <ip1>/<cidr1>[,<ip2>/<cidr2>]...]"
+ " ]...\n";
if (argc < 3) {
- fprintf(stderr, "Usage: %s %s <interface> [listen-port <port>] [fwmark <mark>] [private-key <file path>] [peer <base64 public key> [remove] [preshared-key <file path>] [endpoint <ip>:<port>] [persistent-keepalive <interval seconds>] [allowed-ips <ip1>/<cidr1>[,<ip2>/<cidr2>]...] ]...\n", PROG_NAME, argv[0]);
+ fprintf(stderr, error_message, PROG_NAME, argv[0]);
return 1;
}
--
2.45.2
^ permalink raw reply [flat|nested] 3+ messages in thread
* [PATCH] wireguard-tools: Extracted error message for the sake of legibility
[not found] ` <20240801094932.4502-1-otilibil@eurecom.fr>
@ 2024-08-01 9:43 ` Ariel Otilibili
0 siblings, 0 replies; 3+ messages in thread
From: Ariel Otilibili @ 2024-08-01 9:43 UTC (permalink / raw)
To: wireguard; +Cc: Jason A . Donenfeld, Ariel Otilibili
Signed-off-by: Ariel Otilibili <otilibil@eurecom.fr>
---
src/set.c | 12 +++++++++++-
1 file changed, 11 insertions(+), 1 deletion(-)
diff --git a/src/set.c b/src/set.c
index 75560fd..b2fbd54 100644
--- a/src/set.c
+++ b/src/set.c
@@ -16,9 +16,19 @@ int set_main(int argc, const char *argv[])
{
struct wgdevice *device = NULL;
int ret = 1;
+ const char *error_message = "Usage: %s %s <interface>"
+ " [listen-port <port>]"
+ " [fwmark <mark>]"
+ " [private-key <file path>]"
+ " [peer <base64 public key> [remove]"
+ " [preshared-key <file path>]"
+ " [endpoint <ip>:<port>]"
+ " [persistent-keepalive <interval seconds>]"
+ " [allowed-ips <ip1>/<cidr1>[,<ip2>/<cidr2>]...]"
+ " ]...\n";
if (argc < 3) {
- fprintf(stderr, "Usage: %s %s <interface> [listen-port <port>] [fwmark <mark>] [private-key <file path>] [peer <base64 public key> [remove] [preshared-key <file path>] [endpoint <ip>:<port>] [persistent-keepalive <interval seconds>] [allowed-ips <ip1>/<cidr1>[,<ip2>/<cidr2>]...] ]...\n", PROG_NAME, argv[0]);
+ fprintf(stderr, error_message, PROG_NAME, argv[0]);
return 1;
}
--
2.45.2
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-08-02 16:40 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-07-25 20:42 Extracted error message for the sake of legibility Ariel Otilibili
2024-07-25 20:42 ` [PATCH] " Ariel Otilibili
[not found] ` <20240801094932.4502-1-otilibil@eurecom.fr>
2024-08-01 9:43 ` [PATCH] wireguard-tools: " Ariel Otilibili
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).