log
graph
tags
bookmarks
branches
changeset
browse
file
latest
diff
comparison
annotate
file log
raw
help
Mercurial
>
hg
>
xemacs-beta
annotate lib-src/leditcfns.c @ 3520:
833d460acd43
Find changesets by keywords (author, files, the commit message), revision number or hash, or
revset expression
.
[xemacs-hg @ 2006-07-19 19:35:20 by crestani] 2006-07-18 Marcus Crestani <crestani@xemacs.org> * configure.ac: Intel-based Macs can use POSIX-style write barrier. Use $machine to determine this.
author
crestani
date
Wed, 19 Jul 2006 19:35:25 +0000 (2006-07-19)
parents
376386a54a3c
children
Ignore whitespace changes -
Everywhere:
Within whitespace:
At end of lines:
rev
line source
0
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
1
/* Synched up with: FSF 19.28. */
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
2
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
3
#include <sgtty.h>
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
4
#include <signal.h>
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
5
#define STRLEN 100
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
6
static char str[STRLEN+1] = "%?emacs"; /* extra char for the null */
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
7
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
8
switch_to_proc(){
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
9
char *ptr = str;
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
10
while (*ptr) ioctl(0, TIOCSTI, ptr++);
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
11
ioctl(0, TIOCSTI, "\n");
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
12
kill(getpid(), SIGTSTP);
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
13
}
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
14
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
15
set_proc_str(ptr) char *ptr; {
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
16
if (strlen(ptr) <= STRLEN)
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
17
strcpy(str, ptr);
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
18
else
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
19
printf("string too long for set-proc-str: %s\n", ptr);
376386a54a3c
Import from CVS: tag r19-14
cvs
parents:
diff
changeset
+
−
20
}