From 47a78dcb28c6a836574f73f40b05d4adc9c3ad81 Mon Sep 17 00:00:00 2001 From: markus schnalke Date: Sat, 28 Jan 2012 13:04:59 +0100 Subject: [PATCH] Removed the undocumented -unique switches. Seems they were JLR-only stuff. --- uip/send.c | 24 ++++++------------------ uip/sendsbr.c | 19 +------------------ uip/whatnowsbr.c | 26 +++++++------------------- 3 files changed, 14 insertions(+), 55 deletions(-) diff --git a/uip/send.c b/uip/send.c index c19cf4f..e6d61dc 100644 --- a/uip/send.c +++ b/uip/send.c @@ -33,21 +33,17 @@ static struct swit switches[] = { { "push", 0 }, #define NPUSHSW 9 { "nopush", 0 }, -#define UNIQSW 10 - { "unique", -6 }, -#define NUNIQSW 11 - { "nounique", -8 }, -#define VERBSW 12 +#define VERBSW 10 { "verbose", 0 }, -#define NVERBSW 13 +#define NVERBSW 11 { "noverbose", 0 }, -#define WATCSW 14 +#define WATCSW 12 { "watch", 0 }, -#define NWATCSW 15 +#define NWATCSW 13 { "nowatch", 0 }, -#define VERSIONSW 16 +#define VERSIONSW 14 { "version", 0 }, -#define HELPSW 17 +#define HELPSW 15 { "help", 0 }, { NULL, 0 } }; @@ -56,7 +52,6 @@ extern int debugsw; /* from sendsbr.c */ extern int forwsw; extern int inplace; extern int pushsw; -extern int unique; extern int verbsw; extern char *altmsg; /* .. */ @@ -115,13 +110,6 @@ main(int argc, char **argv) pushsw = 0; continue; - case UNIQSW: - unique++; - continue; - case NUNIQSW: - unique = 0; - continue; - case FORWSW: forwsw++; continue; diff --git a/uip/sendsbr.c b/uip/sendsbr.c index 9c335bd..b2a298c 100644 --- a/uip/sendsbr.c +++ b/uip/sendsbr.c @@ -30,7 +30,6 @@ int debugsw = 0; /* global */ int forwsw = 1; int inplace = 1; int pushsw = 0; -int unique = 0; int verbsw = 0; char *altmsg = NULL; /* .. */ @@ -79,7 +78,7 @@ int sendsbr(char **vec, int vecp, char *drft, struct stat *st, int rename_drft) { int status; - char buffer[BUFSIZ], file[BUFSIZ]; + char buffer[BUFSIZ]; char *original_draft; /* name of original draft file */ char *p; /* string pointer for building file name */ @@ -115,23 +114,7 @@ sendsbr(char **vec, int vecp, char *drft, struct stat *st, int rename_drft) done=armed_done; switch (setjmp(env)) { case OK: - /* - ** If given -push and -unique (which is undocumented), then - ** rename the draft file. I'm not quite sure why. - */ - if (pushsw && unique) { - char *cp = m_mktemp2(drft, invo_name, NULL, NULL); - if (cp == NULL) { - adios("sendsbr", "unable to create temporary file"); - } - if (rename(drft, strncpy(file, cp, sizeof(file))) - == NOTOK) - adios(file, "unable to rename %s to", drft); - drft = file; - } - status = sendaux(vec, vecp, drft, st) ? NOTOK : OK; - /* rename the original draft */ if (rename_drft && status == OK && rename(original_draft, strncpy(buffer, diff --git a/uip/whatnowsbr.c b/uip/whatnowsbr.c index 79f7c6f..3ed0ea4 100644 --- a/uip/whatnowsbr.c +++ b/uip/whatnowsbr.c @@ -846,23 +846,19 @@ static struct swit sendswitches[] = { { "push", 0 }, #define NSPSHSW 9 { "nopush", 0 }, -#define UNIQSW 10 - { "unique", -6 }, -#define NUNIQSW 11 - { "nounique", -8 }, -#define VERBSW 12 +#define VERBSW 10 { "verbose", 0 }, -#define NVERBSW 13 +#define NVERBSW 11 { "noverbose", 0 }, -#define WATCSW 14 +#define WATCSW 12 { "watch", 0 }, -#define NWATCSW 15 +#define NWATCSW 13 { "nowatch", 0 }, -#define WIDTHSW 16 +#define WIDTHSW 14 { "width columns", 0 }, -#define SVERSIONSW 17 +#define SVERSIONSW 15 { "version", 0 }, -#define SHELPSW 18 +#define SHELPSW 16 { "help", 0 }, { NULL, 0 } }; @@ -872,7 +868,6 @@ extern int debugsw; /* from sendsbr.c */ extern int forwsw; extern int inplace; extern int pushsw; -extern int unique; extern int verbsw; extern char *altmsg; /* .. */ @@ -928,7 +923,6 @@ sendit(char *sp, char **arg, char *file, int pushed) debugsw = 0; forwsw = 1; inplace = 1; - unique = 0; altmsg = NULL; annotext = NULL; @@ -964,12 +958,6 @@ sendit(char *sp, char **arg, char *file, int pushed) pushed = 0; continue; - case UNIQSW: - unique++; - continue; - case NUNIQSW: - unique = 0; - continue; case FORWSW: forwsw++; continue; -- 1.7.10.4