[hackers] [surf] Adding a useragent parameter to surf. || Christoph Lohmann
changeset: 259:702870ff07f3
user: Christoph Lohmann <20h_AT_r-36.net>
date: Wed Oct 31 21:25:14 2012 +0100
files: surf.1 surf.c
description:
Adding a useragent parameter to surf.
diff -r 84cc14723325 -r 702870ff07f3 surf.1
--- a/surf.1 Wed Oct 31 21:16:12 2012 +0100
+++ b/surf.1 Wed Oct 31 21:25:14 2012 +0100
_AT_@ -10,6 +10,7 @@
.RB [-r\ scriptfile]
.RB [-s]
.RB [-t\ stylefile]
+.RB [-u\ useragent]
.RB [-v]
.RB [-x]
.RB "URI"
_AT_@ -41,6 +42,9 @@
.B \-t stylefile
Specify the user stylefile.
.TP
+.B \-u useragent
+Specify the user stylefile.
+.TP
.B \-v
Prints version information to standard output, then exits.
.TP
diff -r 84cc14723325 -r 702870ff07f3 surf.c
--- a/surf.c Wed Oct 31 21:16:12 2012 +0100
+++ b/surf.c Wed Oct 31 21:25:14 2012 +0100
_AT_@ -919,7 +919,7 @@
usage(void) {
fputs("surf - simple browser\n", stderr);
die("usage: surf [-c cookiefile] [-e xid] [-i] [-p] [-r scriptfile]"
- " [-s] [-t stylefile] [-v] [-x] [uri]\n");
+ " [-s] [-t stylefile] [-u useragent] [-v] [-x] [uri]\n");
}
void
_AT_@ -967,6 +967,9 @@
case 't':
stylefile = EARGF(usage());
break;
+ case 'u':
+ useragent = EARGF(usage());
+ break;
case 'x':
showxid = TRUE;
break;
Received on Wed Oct 31 2012 - 21:27:35 CET
This archive was generated by hypermail 2.3.0
: Wed Oct 31 2012 - 21:36:07 CET