1 diff -Nur slrn-0.9.8.0.orig/macros/uname.sl slrn-0.9.8.0/macros/uname.sl
2 --- slrn-0.9.8.0.orig/macros/uname.sl 1970-01-01 01:00:00.000000000 +0100
3 +++ slrn-0.9.8.0/macros/uname.sl 2003-08-26 20:30:42.442283944 +0200
5 +% example of customizing User-Agent header
7 +set_string_variable("system_type", uname().sysname + " " + uname().release
8 + + "/" + uname().machine);
9 --- slrn-1.0.2/macros/INSTFILES.orig 2016-06-26 20:26:17.435600753 +0200
10 +++ slrn-1.0.2/macros/INSTFILES 2016-06-26 20:27:20.788590874 +0200
16 diff -Nur slrn-0.9.8.0.orig/src/misc.h slrn-0.9.8.0/src/misc.h
17 --- slrn-0.9.8.0.orig/src/misc.h 2002-10-06 00:19:51.000000000 +0200
18 +++ slrn-0.9.8.0/src/misc.h 2003-08-26 20:30:42.443283792 +0200
21 char *posting_host; /* FQDN or NULL */
28 --- slrn/src/post.c.orig 2008-07-11 07:54:20.000000000 +0200
29 +++ slrn/src/post.c 2008-07-25 20:25:59.896750139 +0200
31 int newsgroups_found=0, subject_found=0, followupto_found=0;
32 Slrn_Mime_Error_Obj *err=NULL;
33 Slrn_Mime_Error_Obj *mime_err;
34 - char *tmp, *system_os_name;
35 + char *tmp, *system_os_name, *User_Agent;
37 + if (Slrn_User_Info.system_type != NULL)
38 + system_os_name = Slrn_User_Info.system_type;
40 system_os_name = slrn_get_os_name ();
41 + if (Slrn_User_Info.user_agent != NULL)
42 + User_Agent = Slrn_User_Info.user_agent;
44 + User_Agent = "slrn";
46 #if SLRN_HAS_STRICT_FROM
47 if (NULL != (tmp = slrn_make_from_string ()))
50 if ((NULL == (tmp = slrn_gen_date_header ()))
51 || (NULL == slrn_append_to_header (a, tmp, 1))
52 - || (NULL == (tmp = slrn_strdup_printf("User-Agent: slrn/%s (%s)", Slrn_Version_String, system_os_name)))
53 + || (NULL == (tmp = slrn_strdup_printf("User-Agent: %s/%s (%s)", User_Agent, Slrn_Version_String, system_os_name)))
54 || (NULL == slrn_append_to_header (a, tmp, 1))
55 || (NULL == slrn_append_to_header (a, NULL,0))) /* separator */
57 --- slrn/src/startup.c.orig 2008-07-10 07:15:22.000000000 +0200
58 +++ slrn/src/startup.c 2008-07-25 20:26:23.960750978 +0200
60 {"followup_custom_headers", &Slrn_Followup_Custom_Headers, NULL},
61 {"reply_custom_headers", &Slrn_Reply_Custom_Headers, NULL},
62 {"supersedes_custom_headers", &Slrn_Supersedes_Custom_Headers, NULL},
63 + {"user_agent", &Slrn_User_Info.user_agent},
64 + {"system_type", &Slrn_User_Info.system_type},
65 #if SLRN_HAS_GROUPLENS
66 {"grouplens_pseudoname", &Slrn_GroupLens_Pseudoname, NULL},
67 {"grouplens_host", &Slrn_GroupLens_Host, NULL},