aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Hacking2
-rw-r--r--README2
-rw-r--r--README.follow6
-rw-r--r--README.term2
-rw-r--r--TODO2
-rw-r--r--beam.c4
-rw-r--r--cmd.c74
-rw-r--r--cmd2.c42
-rwxr-xr-xconfigure73
-rw-r--r--defines.h2
-rw-r--r--eval.c2
-rw-r--r--list.c2
-rw-r--r--log.c2
-rw-r--r--main.c19
-rw-r--r--movie.c8
-rw-r--r--ptr.h2
-rw-r--r--tcp.c14
-rw-r--r--tty.c4
-rw-r--r--utils.c14
19 files changed, 175 insertions, 101 deletions
diff --git a/Hacking b/Hacking
index d91a52f..5cf46d1 100644
--- a/Hacking
+++ b/Hacking
@@ -31,7 +31,7 @@ improve powwow, fix bugs or just have fun:
and README) Also, sending an e-mail to the code author/mantainer documenting
your changes will be appreciated.
-Report from cancan's `Hacking':
+Report from cancan's "Hacking":
*******************************************************************************
Remember, that although I (Yorick) am the original author, I don't dictate
diff --git a/README b/README
index 8731061..3e7adf2 100644
--- a/README
+++ b/README
@@ -79,7 +79,7 @@ INSTALLING
type M-x server-start).
If you want to use the editing functions, you must execute the
- `#identify' command to notify the server that the client supports the
+ "#identify" command to notify the server that the client supports the
protocol. This can also be done with an action; see the documentation
for details.
diff --git a/README.follow b/README.follow
index 8b4e185..9ef923b 100644
--- a/README.follow
+++ b/README.follow
@@ -3,15 +3,15 @@
This mini-program is mainly intended for debugging powwow.
It is completely standalone, and needs to be called with a file-name
-(example: `follow mycapture').
-Hitting ESC or ^C quits `follow', hitting RETURN prints the next line
+(example: "follow mycapture").
+Hitting ESC or ^C quits "follow", hitting RETURN prints the next line
of the file, any other key prints the next character (only one) of the file
I know it is a _stupid_ program, but it is useful if you find screen-related
bugs in powwow, i.e. powwow does not print some lines or prints something
wrong.
In that case, if you redirect powwow output to a file and reproduce the bug,
-you can use `follow your-filename' to examine the file and see what is wrong
+you can use "follow your-filename" to examine the file and see what is wrong
How to send a copy of powwow output to a file:
powwow your-arguments | tee your-filename
diff --git a/README.term b/README.term
index 46d9a73..6dfad6c 100644
--- a/README.term
+++ b/README.term
@@ -15,7 +15,7 @@ Edit any of the other variables you find neccessary.
Read the original README for information you might need to know.
-Then do `make termpowwow'
+Then do "make termpowwow"
Note: Unfortunately one of the setbacks of termpowwow is that it won't
detect unknown hosts, nor will it detect if the host refused the connection.
diff --git a/TODO b/TODO
index 91012de..6112fe9 100644
--- a/TODO
+++ b/TODO
@@ -38,7 +38,7 @@ From the authors of cancan:
THINGS TO DO/PLANNED IMPROVEMENTS on powwow:
- make a better #help
- - add termcap `end of bold', `end of blink' etc.
+ - add termcap "end of bold", "end of blink" etc.
If you have ideas, suggestions or whatever, e-mail them to me
(max@Linuz.sns.it) and if I find them interesting, I will add them.
diff --git a/beam.c b/beam.c
index da92ed9..fc14b5c 100644
--- a/beam.c
+++ b/beam.c
@@ -142,7 +142,7 @@ void abort_edit_fd __P1 (int,fd)
continue;
}
- PRINTF("#aborted `%s' (%u)\n", p->descr, p->key);
+ PRINTF("#aborted \"%s\" (%u)\n", p->descr, p->key);
p->cancel = 1;
}
}
@@ -160,7 +160,7 @@ void cancel_edit __P1 (editsess *,sp)
errmsg("kill editor child");
return;
}
- PRINTF("#killed `%s' (%u)\n", sp->descr, sp->key);
+ PRINTF("#killed \"%s\" (%u)\n", sp->descr, sp->key);
sprintf(keystr, "C%u\n", sp->key);
sprintf(buf, "%sE%d\n%s", MPI, (int)strlen(keystr), keystr);
tcp_write(sp->fd, buf);
diff --git a/cmd.c b/cmd.c
index e06684e..f25a845 100644
--- a/cmd.c
+++ b/cmd.c
@@ -77,7 +77,7 @@ cmdstruct *commands = NULL;
cmdstruct default_commands[] =
{
{NULL,"help", "[keys|math|command]\tthis text, or help on specified topic", cmd_help,NULL},
- {NULL,"17", "command\t\t\trepeat `command' 17 times", (function_str)0,NULL},
+ {NULL,"17", "command\t\t\trepeat \"command\" 17 times", (function_str)0,NULL},
#ifndef NO_SHELL
{NULL,"!", "shell-command\t\texecute a shell command using /bin/sh", cmd_shell,NULL},
#endif
@@ -96,22 +96,22 @@ cmdstruct default_commands[] =
{NULL,"connect", "[connect-id [initstr] [address port]\topen a new connection", cmd_connect,NULL},
{NULL,"cpu", "\t\t\t\tshow CPU time used by powwow", cmd_cpu,NULL},
{NULL,"delim", "[normal|program|{custom [chars]}]\n\t\t\t\tset word completion delimeters", cmd_delim,NULL},
- {NULL,"do", "(expr) command\t\trepeat `command' (expr) times", cmd_do,NULL},
+ {NULL,"do", "(expr) command\t\trepeat \"command\" (expr) times", cmd_do,NULL},
{NULL,"edit", "\t\t\t\tlist editing sessions", cmd_edit,NULL},
{NULL,"emulate", "[<|!]{text|(expr)}\tprocess result as if received from host", cmd_emulate,NULL},
{NULL,"exe", "[<|!]{text|(string-expr)}\texecute result as if typed from keyboard", cmd_exe,NULL},
{NULL,"file", "[=[filename]]\t\tset/show powwow definition file", cmd_file,NULL},
- {NULL,"for", "([init];check;[loop]) command\twhile `check' is true exec `command'", cmd_for,NULL},
- {NULL,"group", "[name] [on|off|list]\tgroup alias/action manipulation'", cmd_group,NULL},
+ {NULL,"for", "([init];check;[loop]) command\twhile \"check\" is true exec \"command\"", cmd_for,NULL},
+ {NULL,"group", "[name] [on|off|list]\tgroup alias/action manipulation", cmd_group,NULL},
{NULL,"hilite", "[attr]\t\t\thighlight your input line", cmd_hilite,NULL},
{NULL,"history", "[{number|(expr)}]\tlist/execute commands in history", cmd_history,NULL},
{NULL,"host", "[hostname port]]\tset/show address of default host", cmd_host,NULL},
{NULL,"identify", "[startact [endact]]\tsend MUME client identification", cmd_identify,NULL},
- {NULL,"if", "(expr) instr1 [; #else instr2]\tif `expr' is true execute `instr1'\n\t\t\t\totherwise execute `instr2'", cmd_if,NULL},
+ {NULL,"if", "(expr) instr1 [; #else instr2]\tif \"expr\" is true execute \"instr1\"\n\t\t\t\totherwise execute \"instr2\"", cmd_if,NULL},
{NULL,"in", "[label [(delay) [command]]]\tdelete/list/define delayed labels", cmd_in,NULL},
{NULL,"init", "[=[command]]\t\tdefine command to execute on connect to host", cmd_init,NULL},
{NULL,"isprompt", "\t\t\trecognize a prompt as such", cmd_isprompt,NULL},
- {NULL,"key", "name\t\t\texecute the `name' key binding", cmd_key,NULL},
+ {NULL,"key", "name\t\t\texecute the \"name\" key binding", cmd_key,NULL},
{NULL,"keyedit", "editing-name\t\trun a line-editing function", cmd_keyedit,NULL},
{NULL,"load", "[filename]\t\tload powwow settings from file", cmd_load,NULL},
#ifdef HAVE_LIBDL
@@ -149,8 +149,8 @@ cmdstruct default_commands[] =
{NULL,"time", "\t\t\t\tprint current time and date", cmd_time,NULL},
{NULL,"var", "variable [= [<|!]{string|(expr)} ]\twrite result into the variable", cmd_var,NULL},
{NULL,"ver", "\t\t\t\tshow powwow version", cmd_ver,NULL},
- {NULL,"while", "(expr) instr\t\twhile `expr' is true execute `instr'", cmd_while,NULL},
- {NULL,"write", "[>|!](expr;name)\t\twrite result of expr to `name' file", cmd_write,NULL},
+ {NULL,"while", "(expr) instr\t\twhile \"expr\" is true execute \"instr\"", cmd_while,NULL},
+ {NULL,"write", "[>|!](expr;name)\t\twrite result of expr to \"name\" file", cmd_write,NULL},
{NULL,"zap", "connect-id\t\t\tclose a connection", cmd_zap,NULL},
{NULL,(char *)0, (char *)0, (function_str)0,NULL}
};
@@ -398,7 +398,7 @@ static void cmd_help __P1 (char *,arg)
f = fopen(helpfile, "r");
if (!f) {
- PRINTF("#cannot open help file `%s': %s\n",
+ PRINTF("#cannot open help file \"%s\": %s\n",
helpfile, strerror(errno));
return;
}
@@ -408,7 +408,7 @@ static void cmd_help __P1 (char *,arg)
;
if (!tmp) {
- PRINTF("#no entry for `%s' in the help file.\n", arg);
+ PRINTF("#no entry for \"%s\" in the help file.\n", arg);
fclose(f);
return;
}
@@ -532,7 +532,7 @@ static void cmd_delim __P1 (char *,arg)
arg = skipspace(arg);
if (!*arg) {
- PRINTF("#delim: `%s' (%s)\n", delim_name[delim_mode], DELIM);
+ PRINTF("#delim: \"%s\" (%s)\n", delim_name[delim_mode], DELIM);
return;
}
@@ -594,7 +594,7 @@ static void cmd_do __P1 (char *,arg)
while (!error && result--)
(void)parse_instruction(arg, 1, 0, 1);
else {
- PRINTF("#do: bogus repeat count `%ld'\n", result);
+ PRINTF("#do: bogus repeat count \"%ld\"\n", result);
}
}
@@ -751,7 +751,7 @@ static void cmd_in __P1 (char *,arg)
if (!*p) p = lookup_delay(name, 1);
if (!*arg && !*p) {
- PRINTF("#unknown delay label, cannot show: `%s'\n", name);
+ PRINTF("#unknown delay label, cannot show: \"%s\"\n", name);
return;
}
if (!*arg) {
@@ -794,7 +794,7 @@ static void cmd_in __P1 (char *,arg)
}
delete_delaynode(p);
} else {
- PRINTF("#unknown delay label, cannot delete: `%s'\n", name);
+ PRINTF("#unknown delay label, cannot delete: \"%s\"\n", name);
}
}
@@ -824,7 +824,7 @@ static void cmd_at __P1 (char *,arg)
if (!*p) p = lookup_delay(name, 1);
if (!*arg && !*p) {
- PRINTF("#unknown delay label, cannot show: `%s'\n", name);
+ PRINTF("#unknown delay label, cannot show: \"%s\"\n", name);
return;
}
if (!*arg) {
@@ -861,7 +861,7 @@ static void cmd_at __P1 (char *,arg)
if (hour < 0 || hour>23 || minute < 0 || minute>59
|| second < 0 || second>59) {
- PRINTF("#at: #error: invalid time `%s'\n",
+ PRINTF("#at: #error: invalid time \"%s\"\n",
pbuf && buf ? buf : (char *)"");
error=OUT_RANGE_ERROR;
ptrdel(pbuf);
@@ -976,7 +976,7 @@ static void cmd_key __P1 (char *,arg)
if ((q = *lookup_key(arg)))
q->funct(q->call_data);
else {
- PRINTF("#no such key: `%s'\n", arg);
+ PRINTF("#no such key: \"%s\"\n", arg);
}
}
@@ -992,7 +992,7 @@ static void cmd_keyedit __P1 (char *,arg)
if ((function = lookup_edit_name(arg, &param)))
internal_functions[function].funct(param);
else {
- PRINTF("#no such editing function: `%s'\n", arg);
+ PRINTF("#no such editing function: \"%s\"\n", arg);
}
}
@@ -1260,7 +1260,7 @@ static void cmd_emulate __P1 (char *,arg)
fp = (kind == '!') ? popen(arg, "r") : fopen(arg, "r");
if (!fp) {
- PRINTF("#emulate: #error opening `%s'\n", arg);
+ PRINTF("#emulate: #error opening \"%s\"\n", arg);
print_error(error=SYNTAX_ERROR);
ptrdel(pbuf);
return;
@@ -1314,7 +1314,7 @@ static void cmd_exe __P1 (char *,arg)
fp = (kind == '!') ? popen(arg, "r") : fopen(arg, "r");
if (!fp) {
- PRINTF("#exe: #error opening `%s'\n", arg);
+ PRINTF("#exe: #error opening \"%s\"\n", arg);
error = SYNTAX_ERROR;
ptrdel(pbuf);
return;
@@ -1353,7 +1353,7 @@ static void cmd_print __P1 (char *,arg)
char buf[BUFSIZE];
fp = (kind == '!') ? popen(arg, "r") : fopen(arg, "r");
if (!fp) {
- PRINTF("#print: #error opening `%s'\n", arg);
+ PRINTF("#print: #error opening \"%s\"\n", arg);
error=SYNTAX_ERROR;
ptrdel(pbuf);
return;
@@ -1384,7 +1384,7 @@ static void cmd_send __P1 (char *,arg)
char buf[BUFSIZE];
fp = (kind == '!') ? popen(arg, "r") : fopen(arg, "r");
if (!fp) {
- PRINTF("#send: #error opening `%s'\n", arg);
+ PRINTF("#send: #error opening \"%s\"\n", arg);
error = SYNTAX_ERROR;
ptrdel(pbuf);
return;
@@ -1490,7 +1490,7 @@ static void cmd_write __P1 (char *,arg)
fp = (kind == '!') ? popen(arg, "w") : fopen(arg, kind ? "w" : "a");
if (!fp) {
- PRINTF("#write: #error opening `%s'\n", arg);
+ PRINTF("#write: #error opening \"%s\"\n", arg);
error=SYNTAX_ERROR;
goto write_cleanup2;
}
@@ -1565,7 +1565,7 @@ static void cmd_var __P1 (char *,arg)
if (REAL_ERROR)
return;
if (echo_int) {
- PRINTF("#new variable: `%s'\n", arg - 1);
+ PRINTF("#new variable: \"%s\"\n", arg - 1);
}
} else {
print_error(error=UNDEFINED_VARIABLE_ERROR);
@@ -1661,11 +1661,11 @@ static void cmd_var __P1 (char *,arg)
/* R.I.P. named variables */
if (named_var) {
if (is_permanent_variable(named_var)) {
- PRINTF("#cannot delete variable: `%s'\n", arg - 1);
+ PRINTF("#cannot delete variable: \"%s\"\n", arg - 1);
} else {
delete_varnode(p_named_var, kind);
if (echo_int) {
- PRINTF("#deleted variable: `%s'\n", arg - 1);
+ PRINTF("#deleted variable: \"%s\"\n", arg - 1);
}
}
} else if ((type = TYPE_TXT_VAR)) {
@@ -1724,7 +1724,7 @@ static void cmd_var __P1 (char *,arg)
char buf2[BUFSIZE];
fp = (kind == '!') ? popen(arg, "r") : fopen(arg, "r");
if (!fp) {
- PRINTF("#var: #error opening `%s'\n", arg);
+ PRINTF("#var: #error opening \"%s\"\n", arg);
error=SYNTAX_ERROR;
ptrdel(pbuf);
return;
@@ -2022,9 +2022,9 @@ static void cmd_capture __P1 (char *,arg)
append = 1;
}
if ((capturefile = fopen(arg, (append) ? "a" : "w")) == NULL) {
- PRINTF("#error writing file `%s'\n", arg);
+ PRINTF("#error writing file \"%s\"\n", arg);
} else if (echo_int) {
- PRINTF("#capture to `%s' active, `#capture' ends.\n", arg);
+ PRINTF("#capture to \"%s\" active, \"#capture\" ends.\n", arg);
}
}
}
@@ -2050,10 +2050,10 @@ static void cmd_movie __P1 (char *,arg)
PRINTF("#movie already active.\n");
} else {
if ((moviefile = fopen(arg, "w")) == NULL) {
- PRINTF("#error writing file `%s'\n", arg);
+ PRINTF("#error writing file \"%s\"\n", arg);
} else {
if (echo_int) {
- PRINTF("#movie to `%s' active, `#movie' ends.\n", arg);
+ PRINTF("#movie to \"%s\" active, \"#movie\" ends.\n", arg);
}
update_now();
movie_last = now;
@@ -2082,9 +2082,9 @@ static void cmd_record __P1 (char *,arg)
PRINTF("#record already active.\n");
} else {
if ((recordfile = fopen(arg, "w")) == NULL) {
- PRINTF("#error writing file `%s'\n", arg);
+ PRINTF("#error writing file \"%s\"\n", arg);
} else if (echo_int) {
- PRINTF("#record to `%s' active, `#record' ends.\n", arg);
+ PRINTF("#record to \"%s\" active, \"#record\" ends.\n", arg);
}
}
}
@@ -2337,7 +2337,7 @@ keyecho speedwalk wrap autoprint reprint sendsize autoclear\n");
reprint_clear();
/* as above, but always print status if
- * `#option info' alone was typed */
+ * "#option info" alone was typed */
if (mode != MODE_REP && !*arg && count==1 &&
(echo_int || (mode == MODE_TOGGLE && varp==&echo_int))) {
PRINTF("#option %s is now o%s.\n", str[i],
@@ -2372,7 +2372,7 @@ static void cmd_file __P1 (char *,arg)
set_deffile(++arg);
if (echo_int) {
if (*arg) {
- PRINTF("#save-file set to `%s'\n", deffile);
+ PRINTF("#save-file set to \"%s\"\n", deffile);
} else {
PRINTF("#save-file is now undefined.\n");
}
@@ -2390,7 +2390,7 @@ static void cmd_save __P1 (char *,arg)
if (*arg) {
set_deffile(arg);
if (echo_int) {
- PRINTF("#save-file set to `%s'\n", deffile);
+ PRINTF("#save-file set to \"%s\"\n", deffile);
}
} else if (!*deffile) {
PRINTF("#save-file not defined.\n");
@@ -2410,7 +2410,7 @@ static void cmd_load __P1 (char *,arg)
if (*arg) {
set_deffile(arg);
if (echo_int) {
- PRINTF("#save-file set to `%s'\n", deffile);
+ PRINTF("#save-file set to \"%s\"\n", deffile);
}
}
else if (!*deffile) {
diff --git a/cmd2.c b/cmd2.c
index b43f68b..a94e868 100644
--- a/cmd2.c
+++ b/cmd2.c
@@ -88,12 +88,12 @@ static int check_alias __P1 (char *,name)
return 1;
}
if (*p == '{') {
- PRINTF("#illegal beginning '{' in alias name: `%s'\n", name);
+ PRINTF("#illegal beginning '{' in alias name: \"%s\"\n", name);
error = INVALID_NAME_ERROR;
return 1;
}
if (strchr(name, ' ')) {
- PRINTF("#illegal spaces in alias name: `%s'\n", name);
+ PRINTF("#illegal spaces in alias name: \"%s\"\n", name);
error = INVALID_NAME_ERROR;
return 1;
}
@@ -129,13 +129,13 @@ static int check_alias __P1 (char *,name)
}
if (!ok) {
- PRINTF("#illegal non-escaped `;' in alias name: `%s'\n", name);
+ PRINTF("#illegal non-escaped ';' in alias name: \"%s\"\n", name);
error = INVALID_NAME_ERROR;
return 1;
}
if (quotes || paren || braces) {
- PRINTF("#warning: unbalanced%s%s%s in alias name `%s' may cause problems\n",
+ PRINTF("#warning: unbalanced%s%s%s in alias name \"%s\" may cause problems\n",
quotes ? " \"\"" : "", paren ? " ()" : "", braces ? " {}" : "", name);
}
@@ -178,7 +178,7 @@ void parse_alias __P1 (char *,str)
}
delete_aliasnode(np);
} else {
- PRINTF("#unknown alias, cannot delete: `%s'\n", left);
+ PRINTF("#unknown alias, cannot delete: \"%s\"\n", left);
}
} else {
/* add/redefine alias */
@@ -221,7 +221,7 @@ void parse_alias __P1 (char *,str)
(*np)->group == NULL ? "*" : (*np)->group,
BUFSIZE-(int)strlen(buf)-9, (*np)->subst);
} else {
- PRINTF("#unknown alias, cannot show: `%s'\n", left);
+ PRINTF("#unknown alias, cannot show: \"%s\"\n", left);
}
}
}
@@ -439,7 +439,7 @@ void parse_action __P2 (char *,str, int,onprompt)
/* '<' : remove action */
if (assign == '<') {
if (!np || !*np) {
- PRINTF("#no %s, cannot delete label: `%s'\n",
+ PRINTF("#no %s, cannot delete label: \"%s\"\n",
ONPROMPT, label);
}
else {
@@ -586,7 +586,7 @@ void parse_action __P2 (char *,str, int,onprompt)
BUFSIZE - 6 /*strlen(ONPROMPT)*/ - 7 - len - (int)strlen((*np)->pattern),
(*np)->command);
} else {
- PRINTF("#no %s, cannot list label: `%s'\n", ONPROMPT, label);
+ PRINTF("#no %s, cannot list label: \"%s\"\n", ONPROMPT, label);
}
/* '+', '-': turn action on/off */
@@ -600,7 +600,7 @@ void parse_action __P2 (char *,str, int,onprompt)
(*np)->pattern, (sign == '+') ? "n" : "ff");
}
} else {
- PRINTF("#no %s, cannot turn o%s label: `%s'\n", ONPROMPT,
+ PRINTF("#no %s, cannot turn o%s label: \"%s\"\n", ONPROMPT,
(sign == '+') ? "n" : "ff", label);
}
}
@@ -629,7 +629,7 @@ void parse_action __P2 (char *,str, int,onprompt)
else if (np && *np)
delete_action(np);
else {
- PRINTF("#no action, cannot delete pattern: `%s'\n",
+ PRINTF("#no action, cannot delete pattern: \"%s\"\n",
pattern);
return;
}
@@ -641,7 +641,7 @@ void parse_action __P2 (char *,str, int,onprompt)
BUFSIZE - (int)strlen((*np)->pattern) - 10,
(*np)->command);
} else {
- PRINTF("#no action, cannot show pattern: `%s'\n", pattern);
+ PRINTF("#no action, cannot show pattern: \"%s\"\n", pattern);
}
}
}
@@ -908,7 +908,7 @@ void parse_mark __P1 (char *,str)
BUFSIZE-9, name);
ptrdel(pbuf);
} else {
- PRINTF("#unknown marker, cannot show: `%s'\n", str);
+ PRINTF("#unknown marker, cannot show: \"%s\"\n", str);
}
} else {
@@ -948,7 +948,7 @@ void parse_mark __P1 (char *,str)
}
delete_marknode(np);
} else {
- PRINTF("#unknown marker, cannot delete: `%s%s'\n",
+ PRINTF("#unknown marker, cannot delete: \"%s%s\"\n",
mbeg ? "^" : "", pattern);
}
else {
@@ -1144,7 +1144,7 @@ char *read_seq __P2 (char *,name, int *,len)
static char seq[CAPLEN];
int i = 1, tmp;
- PRINTF("#please press the key `%s' : ", name);
+ PRINTF("#please press the key \"%s\" : ", name);
tty_flush();
if ((tmp = get_one_char(0)) >= 0)
@@ -1255,7 +1255,7 @@ static void parse_bind_noninteractive __P1 (char *,arg)
p = strchr(arg, ' ');
if (!p) {
- PRINTF("#syntax error: `#bind %s'\n", arg);
+ PRINTF("#syntax error: \"#bind %s\"\n", arg);
return;
}
*(p++) = '\0';
@@ -1263,7 +1263,7 @@ static void parse_bind_noninteractive __P1 (char *,arg)
p = unescape_seq(rawseq, p, &seqlen);
if (!p[0] || !p[1]) {
- PRINTF("#syntax error: `#bind %s %s'\n", arg, seq);
+ PRINTF("#syntax error: \"#bind %s %s\"\n", arg, seq);
return;
}
*p++ = '\0';
@@ -1331,7 +1331,7 @@ void parse_bind __P1 (char *,arg)
show_single_bind("deleting key binding:", np);
delete_keynode(npp);
} else {
- PRINTF("#no such key: `%s'\n", name);
+ PRINTF("#no such key: \"%s\"\n", name);
}
}
} else {
@@ -1356,7 +1356,7 @@ void parse_bind __P1 (char *,arg)
np->call_data ? np->call_data : "");
}
} else {
- PRINTF("#no such key: `%s'\n", name);
+ PRINTF("#no such key: \"%s\"\n", name);
}
}
}
@@ -1381,7 +1381,7 @@ void parse_rebind __P1 (char *,arg)
kp = lookup_key(arg);
if (!kp || !*kp) {
- PRINTF("#no such key: `%s'\n", arg);
+ PRINTF("#no such key: \"%s\"\n", arg);
return;
}
@@ -1416,7 +1416,7 @@ void parse_rebind __P1 (char *,arg)
/*
* evaluate an expression, or unescape a text.
* set value of start and end line if <(expression...) or !(expression...)
- * if needed, use/malloc `pbuf' as buffer (on error, also free pbuf)
+ * if needed, use/malloc "pbuf" as buffer (on error, also free pbuf)
* return resulting char *
*/
char *redirect __P7 (char *,arg, ptr *,pbuf, char *,kind, char *,name, int,also_num, long *,start, long *,end)
@@ -1568,7 +1568,7 @@ void show_delaynode __P2 (delaynode *,p, int,in_or_at)
BUFSIZE - LONGLEN - 9 - (int)strlen(p->name), p->command);
} else {
(void)strftime(buf, BUFSIZE - 1, "%H:%M:%S", s);
- PRINTF("#at (%s) #in (%ld) `%s' %s\n", buf, d, p->name, p->command);
+ PRINTF("#at (%s) #in (%ld) \"%s\" %s\n", buf, d, p->name, p->command);
}
}
diff --git a/configure b/configure
index 664cccf..913b228 100755
--- a/configure
+++ b/configure
@@ -3159,6 +3159,79 @@ _ACEOF
fi
+echo "$as_me:$LINENO: checking for dlopen in -ldl" >&5
+echo $ECHO_N "checking for dlopen in -ldl... $ECHO_C" >&6
+if test "${ac_cv_lib_dl_dlopen+set}" = set; then
+ echo $ECHO_N "(cached) $ECHO_C" >&6
+else
+ ac_check_lib_save_LIBS=$LIBS
+LIBS="-ldl $LIBS"
+cat >conftest.$ac_ext <<_ACEOF
+/* confdefs.h. */
+_ACEOF
+cat confdefs.h >>conftest.$ac_ext
+cat >>conftest.$ac_ext <<_ACEOF
+/* end confdefs.h. */
+
+/* Override any gcc2 internal prototype to avoid an error. */
+#ifdef __cplusplus
+extern "C"
+#endif
+/* We use char because int might match the return type of a gcc2
+ builtin and then its argument prototype would still apply. */
+char dlopen ();
+int
+main ()
+{
+dlopen ();
+ ;
+ return 0;
+}
+_ACEOF
+rm -f conftest.$ac_objext conftest$ac_exeext
+if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
+ (eval $ac_link) 2>conftest.er1
+ ac_status=$?
+ grep -v '^ *+' conftest.er1 >conftest.err
+ rm -f conftest.er1
+ cat conftest.err >&5
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); } &&
+ { ac_try='test -z "$ac_c_werror_flag" || test ! -s conftest.err'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; } &&
+ { ac_try='test -s conftest$ac_exeext'
+ { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
+ (eval $ac_try) 2>&5
+ ac_status=$?
+ echo "$as_me:$LINENO: \$? = $ac_status" >&5
+ (exit $ac_status); }; }; then
+ ac_cv_lib_dl_dlopen=yes
+else
+ echo "$as_me: failed program was:" >&5
+sed 's/^/| /' conftest.$ac_ext >&5
+
+ac_cv_lib_dl_dlopen=no
+fi
+rm -f conftest.err conftest.$ac_objext \
+ conftest$ac_exeext conftest.$ac_ext
+LIBS=$ac_check_lib_save_LIBS
+fi
+echo "$as_me:$LINENO: result: $ac_cv_lib_dl_dlopen" >&5
+echo "${ECHO_T}$ac_cv_lib_dl_dlopen" >&6
+if test $ac_cv_lib_dl_dlopen = yes; then
+ cat >>confdefs.h <<_ACEOF
+#define HAVE_LIBDL 1
+_ACEOF
+
+ LIBS="-ldl $LIBS"
+
+fi
+
+
# Checks for header files.
ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
diff --git a/defines.h b/defines.h
index 493d8a1..88f24d2 100644
--- a/defines.h
+++ b/defines.h
@@ -264,7 +264,7 @@ typedef struct sortednode {
} sortednode;
/*
- * linked list nodes: keep `next' first, then string to sort by,
+ * linked list nodes: keep "next" first, then string to sort by,
* then (eventually) `snext'
*/
typedef struct aliasnode {
diff --git a/eval.c b/eval.c
index 8105e47..03f6b16 100644
--- a/eval.c
+++ b/eval.c
@@ -113,7 +113,7 @@ char *error_msg[] = {
"numeric value expected",
"string expected",
"missing label",
- "missing separator `;'",
+ "missing separator \";\"",
"#history recursion too deep",
"user break",
"too many defined variables",
diff --git a/list.c b/list.c
index eb2fe51..df0bfc4 100644
--- a/list.c
+++ b/list.c
@@ -165,7 +165,7 @@ static sortednode **selflookup_sortednode __P2 (sortednode *,self, sortednode **
while (*p && *p != self)
p = &(*p)->snext;
if (!*p) {
- PRINTF("#internal error, selflookup_sortednode(`%s') failed!\n", self->sortfield);
+ PRINTF("#internal error, selflookup_sortednode(\"%s\") failed!\n", self->sortfield);
error = INTERNAL_ERROR;
}
return p;
diff --git a/log.c b/log.c
index f4cc90c..3f17342 100644
--- a/log.c
+++ b/log.c
@@ -41,7 +41,7 @@ static int datasize = 0; /* size of circular string list */
typedef struct logentry {
enum linetype kind;
long msecs; /* millisecs to sleep if kind == SLEEP */
- char *line; /* pointer to string in `datalist' circular buffer */
+ char *line; /* pointer to string in "datalist" circular buffer */
} logentry;
logentry *loglist; /* circular (pointer to string) list */
diff --git a/main.c b/main.c
index 547ec72..e0877af 100644
--- a/main.c
+++ b/main.c
@@ -31,6 +31,7 @@
*/
#define POWWOW_VERSION VERSION ", Copyright 2000-2005 by Cosmos\n" \
+ " Copyright 2005 by bpk - http://hoopajoo.net\n" \
"(contributions by Yorick, Vivriel, Thuzzle, Ilie, Fror, Dain)\n"
#define HELPNAME "powwow.help"
#define COPYNAME "COPYING"
@@ -318,9 +319,9 @@ int main __P2 (int,argc, char **,argv)
if (argc == 1) {
tty_printf(
-"\nPowwow comes with ABSOLUTELY NO WARRANTY; for details type `#help warranty'.\n\
+"\nPowwow comes with ABSOLUTELY NO WARRANTY; for details type \"#help warranty\".\n\
This is free software, and you are welcome to redistribute it\n\
-under certain conditions; type `#help copyright' for details.\n"
+under certain conditions; type \"#help copyright\" for details.\n"
);
}
@@ -841,7 +842,7 @@ static int process_first_fragment __P2 (char *,buf, int,got)
* Kludge for kludge: don't delete the old prompt immediately.
* Instead, match actions on it first.
* If it matches, clear the line before running the action
- * (done by the `1' in search_action() )
+ * (done by the "1" in search_action() )
* If it doesn't match, delete it only if opt_compact != 0
*/
@@ -1135,7 +1136,7 @@ static int match_weak_action __P4 (char *,pat, char *,line, int *,match_s, int *
if (c == '$')
mword = 1;
} else {
- PRINTF("#error: bad action pattern `%s\'\n#missing digit after `%s\'\n",
+ PRINTF("#error: bad action pattern \"%s\"\n#missing digit after \"%s\"\n",
realpat, pat);
DROP_PTR(pbuf);
return 0;
@@ -1222,7 +1223,7 @@ static int match_weak_action __P4 (char *,pat, char *,line, int *,match_s, int *
static int search_action_or_prompt __P3 (char *,line, char,clearline, char,onprompt)
{
/*
- * we need actionnode and promptnode to be the same `triggernode' type
+ * we need actionnode and promptnode to be the same "triggernode" type
*/
triggernode *p;
int ret = 0;
@@ -1614,7 +1615,7 @@ char *parse_instruction __P4 (char *,line, char,silent, char,subs, char,jit_subs
otcp_fd = tcp_fd;
if ((tcp_fd = tcp_find(buf))<0) {
error = OUT_RANGE_ERROR;
- PRINTF("#no connection named `%s'\n", buf);
+ PRINTF("#no connection named \"%s\"\n", buf);
break;
}
arg = skipspace(line);
@@ -1669,7 +1670,7 @@ char *parse_instruction __P4 (char *,line, char,silent, char,subs, char,jit_subs
pop_params();
/* now check for internal commands */
- /* placed here to allow also aliases starting with `#' */
+ /* placed here to allow also aliases starting with "#" */
} else if (*(end = skipspace(line)) == '#') {
if (*(end = skipspace(end + 1)) == '(') { /* execute #() */
@@ -1742,7 +1743,7 @@ static void parse_commands __P2 (char *,command, char *,arg)
}
}
- PRINTF("#unknown powwow command `%s'\n", command);
+ PRINTF("#unknown powwow command \"%s\"\n", command);
}
}
@@ -1827,7 +1828,7 @@ static int subst_param __P2 (ptr *,buf, char *,src)
/*
* just-in-time substitution:
* substitute ${name}, @{name} and #{expression} in a string
- * (unless `${', `@{' or `#{' are escaped with backslash)
+ * (unless "${", "@{" or "#{" are escaped with backslash)
*
* return 0 if dst not filled. if returned 0 and not error,
* there was nothing to substitute.
diff --git a/movie.c b/movie.c
index 093fd31..e88d5ee 100644
--- a/movie.c
+++ b/movie.c
@@ -30,7 +30,7 @@ int argc; char *argv[];
if (strstr(argv[0], "movie_play"))
play = 1;
else if (!strstr(argv[0], "movie2ascii")) {
- fprintf(stderr, "Please run this program as `movie_play' or `movie2ascii'\n");
+ fprintf(stderr, "Please run this program as \"movie_play\" or \"movie2ascii\"\n");
return 1;
}
@@ -39,7 +39,7 @@ int argc; char *argv[];
infile = fopen(argv[1], "rb");
outfile = stdout;
if (infile == NULL) {
- fprintf(stderr, "Error opening input file `%s'\n", argv[1]);
+ fprintf(stderr, "Error opening input file \"%s\"\n", argv[1]);
return 1;
}
} else {
@@ -51,11 +51,11 @@ int argc; char *argv[];
infile = fopen(argv[1], "rb");
outfile = fopen(argv[2], "wb");
if (infile == NULL) {
- fprintf(stderr, "Error opening input file `%s'\n", argv[1]);
+ fprintf(stderr, "Error opening input file \"%s\"\n", argv[1]);
return 1;
}
if (outfile == NULL) {
- fprintf(stderr, "Error opening output file `%s'\n", argv[2]);
+ fprintf(stderr, "Error opening output file \"%s\"\n", argv[2]);
return 1;
}
} else {
diff --git a/ptr.h b/ptr.h
index ebdf09d..06a0271 100644
--- a/ptr.h
+++ b/ptr.h
@@ -1,5 +1,5 @@
/*
- * ptr.h -- type definitions for ptr (aka `pointer'), a char* replacement
+ * ptr.h -- type definitions for ptr (aka "pointer"), a char* replacement
* which allows for '\0' inside a string.
*/
diff --git a/tcp.c b/tcp.c
index 3d0a3fe..31c90c0 100644
--- a/tcp.c
+++ b/tcp.c
@@ -769,7 +769,7 @@ void tcp_open __P4 (char *,id, char *,initstring, char *,host, int,port)
return;
}
if (tcp_find(id)>=0) {
- PRINTF("#connection `%s' already open.\n", id);
+ PRINTF("#connection \"%s\" already open.\n", id);
return;
}
@@ -816,7 +816,7 @@ void tcp_open __P4 (char *,id, char *,initstring, char *,host, int,port)
tcp_count++;
if (echo_int && tcp_count) {
- PRINTF("#default connection is now `%s'\n", id);
+ PRINTF("#default connection is now \"%s\"\n", id);
}
tcp_set_main(tcp_fd = newtcp_fd);
if (opt_sendsize)
@@ -845,7 +845,7 @@ void tcp_close __P1 (char *,id)
if (id) { /* #zap cmd */
if ((sfd = tcp_find(id)) < 0) {
- tty_printf("#no such connection: `%s'\n", id);
+ tty_printf("#no such connection: \"%s\"\n", id);
return;
}
} else
@@ -856,7 +856,7 @@ void tcp_close __P1 (char *,id)
abort_edit_fd(sfd);
- tty_printf("#connection on `%s' closed.\n", CONN_LIST(sfd).id);
+ tty_printf("#connection on \"%s\" closed.\n", CONN_LIST(sfd).id);
if (sfd == tcp_main_fd) { /* main connection closed */
if (tcp_count == 1) { /* was last connection */
@@ -870,7 +870,7 @@ void tcp_close __P1 (char *,id)
if (!CONN_INDEX(i).id || CONN_INDEX(i).fd == sfd
|| (CONN_INDEX(i).flags & SPAWN))
continue;
- tty_printf("#default connection is now `%s'\n", CONN_INDEX(i).id);
+ tty_printf("#default connection is now \"%s\"\n", CONN_INDEX(i).id);
tcp_main_fd = CONN_INDEX(i).fd;
break;
}
@@ -940,7 +940,7 @@ void tcp_spawn __P2 (char *,id, char *,cmd)
int i, childpid, sockets[2];
if (tcp_find(id)>=0) {
- PRINTF("#connection `%s' already open.\n", id);
+ PRINTF("#connection \"%s\" already open.\n", id);
return;
}
if (socketpair(AF_UNIX, SOCK_STREAM, 0, sockets) < 0) {
@@ -1011,7 +1011,7 @@ void tcp_spawn __P2 (char *,id, char *,cmd)
conn_max_index = i+1;
if (echo_int) {
- PRINTF("#successfully spawned `%s' with pid %d\n", id, childpid);
+ PRINTF("#successfully spawned \"%s\" with pid %d\n", id, childpid);
}
/*
diff --git a/tty.c b/tty.c
index c2d0cb7..0ac7b3c 100644
--- a/tty.c
+++ b/tty.c
@@ -347,7 +347,7 @@ void tty_bootstrap __P0 (void)
break;
case 0:
fprintf(stderr,
- "There is no entry for `%s' in the terminal data base.\n", term);
+ "There is no entry for \"%s\" in the terminal data base.\n", term);
fprintf(stderr,
"Please set your $TERM environment variable correctly.\n");
exit(1);
@@ -359,7 +359,7 @@ void tty_bootstrap __P0 (void)
if (np->len) *np->len += i;
} else if (np->critic) {
fprintf(stderr,
- "Your `%s' terminal is not powerful enough, missing `%s'.\n",
+ "Your \"%s\" terminal is not powerful enough, missing \"%s\".\n",
term, np->cap);
exit(1);
}
diff --git a/utils.c b/utils.c
index 8ec96eb..52d7c10 100644
--- a/utils.c
+++ b/utils.c
@@ -851,7 +851,7 @@ static void load_missing_stuff __P1 (int,n)
parse_alias(buf);
limit_mem = 1048576;
tty_printf("#compatibility aliases loaded:\n\t%s\n", "#lines, #settimer");
- tty_puts("#max text/strings length set to 1048576 bytes\n\tuse `#setvar mem' to change it\n\n#wait...");
+ tty_puts("#max text/strings length set to 1048576 bytes\n\tuse \"#setvar mem\" to change it\n\n#wait...");
tty_flush();
sleep(1);
tty_puts("ok\n");
@@ -880,7 +880,7 @@ int read_settings __P0 (void)
f = fopen(deffile, "r");
if (!f) {
- PRINTF("#error: cannot open file `%s': %s\n", deffile, strerror(errno));
+ PRINTF("#error: cannot open file \"%s\": %s\n", deffile, strerror(errno));
return 0;
}
@@ -941,7 +941,7 @@ int read_settings __P0 (void)
if (!cmd) {
if (feof(f)) {
- PRINTF("#error: missing newline at end of file `%s'\n", deffile);
+ PRINTF("#error: missing newline at end of file \"%s\"\n", deffile);
break;
}
/* no newline yet. increase line size and try again */
@@ -981,7 +981,7 @@ int read_settings __P0 (void)
if (error)
failed = -1;
else if (ferror(f) && !feof(f)) {
- PRINTF("#error: cannot read file `%s': %s\n", deffile, strerror(errno));
+ PRINTF("#error: cannot read file \"%s\": %s\n", deffile, strerror(errno));
failed = -1;
} else if (limit_mem_hit) {
PRINTF("#error: cannot load save-file: got a line longer than limit\n");
@@ -1006,7 +1006,7 @@ static char tmpname[BUFSIZE];
static void fail_msg __P0 (void)
{
- PRINTF("#error: cannot write to temporary file `%s': %s\n", tmpname, strerror(errno));
+ PRINTF("#error: cannot write to temporary file \"%s\": %s\n", tmpname, strerror(errno));
}
/*
@@ -1240,7 +1240,7 @@ int save_settings __P0 (void)
else {
failed = rename(tmpname, deffile);
if (failed == -1) {
- PRINTF("#error: cannot move temporary file `%s' to `%s': %s\n",
+ PRINTF("#error: cannot move temporary file \"%s\" to \"%s\": %s\n",
tmpname, deffile, strerror(errno));
} else
failed = 1;
@@ -1253,7 +1253,7 @@ int save_settings __P0 (void)
}
/*
- * update `now' to current time
+ * update "now" to current time
*/
void update_now __P0 (void)
{