aboutsummaryrefslogtreecommitdiffstats
path: root/src/sysdep.c
diff options
context:
space:
mode:
authorDmitry Antipov2012-08-01 10:23:24 +0400
committerDmitry Antipov2012-08-01 10:23:24 +0400
commit3193acd258557340907a7281d067fdbb426c2f54 (patch)
tree533f741701969dc6dcb6111ed3c64549fbc0c79a /src/sysdep.c
parent3a45383a47009a5e6a15a4005ad95ecf63539182 (diff)
downloademacs-3193acd258557340907a7281d067fdbb426c2f54.tar.gz
emacs-3193acd258557340907a7281d067fdbb426c2f54.zip
Use INTERNAL_FIELD for processes.
* src/process.h (PVAR): New macro. Adjust style. (struct Lisp_Process): Change Lisp_Object members to INTERNAL_FIELD. * src/print.c, src/process.c, src/sysdep.c, src/w32.c: * src/xdisp.c: Users changed. * admin/coccinelle/process.cocci: Semantic patch to replace direct access to Lisp_Object members of struct Lisp_Process to PVAR.
Diffstat (limited to 'src/sysdep.c')
-rw-r--r--src/sysdep.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/sysdep.c b/src/sysdep.c
index 6ce583b3d53..2bfdb35fdfb 100644
--- a/src/sysdep.c
+++ b/src/sysdep.c
@@ -2156,7 +2156,7 @@ serial_configure (struct Lisp_Process *p,
2156 int err = -1; 2156 int err = -1;
2157 char summary[4] = "???"; /* This usually becomes "8N1". */ 2157 char summary[4] = "???"; /* This usually becomes "8N1". */
2158 2158
2159 childp2 = Fcopy_sequence (p->childp); 2159 childp2 = Fcopy_sequence (PVAR (p, childp));
2160 2160
2161 /* Read port attributes and prepare default configuration. */ 2161 /* Read port attributes and prepare default configuration. */
2162 err = tcgetattr (p->outfd, &attr); 2162 err = tcgetattr (p->outfd, &attr);
@@ -2174,7 +2174,7 @@ serial_configure (struct Lisp_Process *p,
2174 if (!NILP (Fplist_member (contact, QCspeed))) 2174 if (!NILP (Fplist_member (contact, QCspeed)))
2175 tem = Fplist_get (contact, QCspeed); 2175 tem = Fplist_get (contact, QCspeed);
2176 else 2176 else
2177 tem = Fplist_get (p->childp, QCspeed); 2177 tem = Fplist_get (PVAR (p, childp), QCspeed);
2178 CHECK_NUMBER (tem); 2178 CHECK_NUMBER (tem);
2179 err = cfsetspeed (&attr, XINT (tem)); 2179 err = cfsetspeed (&attr, XINT (tem));
2180 if (err != 0) 2180 if (err != 0)
@@ -2186,7 +2186,7 @@ serial_configure (struct Lisp_Process *p,
2186 if (!NILP (Fplist_member (contact, QCbytesize))) 2186 if (!NILP (Fplist_member (contact, QCbytesize)))
2187 tem = Fplist_get (contact, QCbytesize); 2187 tem = Fplist_get (contact, QCbytesize);
2188 else 2188 else
2189 tem = Fplist_get (p->childp, QCbytesize); 2189 tem = Fplist_get (PVAR (p, childp), QCbytesize);
2190 if (NILP (tem)) 2190 if (NILP (tem))
2191 tem = make_number (8); 2191 tem = make_number (8);
2192 CHECK_NUMBER (tem); 2192 CHECK_NUMBER (tem);
@@ -2207,7 +2207,7 @@ serial_configure (struct Lisp_Process *p,
2207 if (!NILP (Fplist_member (contact, QCparity))) 2207 if (!NILP (Fplist_member (contact, QCparity)))
2208 tem = Fplist_get (contact, QCparity); 2208 tem = Fplist_get (contact, QCparity);
2209 else 2209 else
2210 tem = Fplist_get (p->childp, QCparity); 2210 tem = Fplist_get (PVAR (p, childp), QCparity);
2211 if (!NILP (tem) && !EQ (tem, Qeven) && !EQ (tem, Qodd)) 2211 if (!NILP (tem) && !EQ (tem, Qeven) && !EQ (tem, Qodd))
2212 error (":parity must be nil (no parity), `even', or `odd'"); 2212 error (":parity must be nil (no parity), `even', or `odd'");
2213#if defined (PARENB) && defined (PARODD) && defined (IGNPAR) && defined (INPCK) 2213#if defined (PARENB) && defined (PARODD) && defined (IGNPAR) && defined (INPCK)
@@ -2240,7 +2240,7 @@ serial_configure (struct Lisp_Process *p,
2240 if (!NILP (Fplist_member (contact, QCstopbits))) 2240 if (!NILP (Fplist_member (contact, QCstopbits)))
2241 tem = Fplist_get (contact, QCstopbits); 2241 tem = Fplist_get (contact, QCstopbits);
2242 else 2242 else
2243 tem = Fplist_get (p->childp, QCstopbits); 2243 tem = Fplist_get (PVAR (p, childp), QCstopbits);
2244 if (NILP (tem)) 2244 if (NILP (tem))
2245 tem = make_number (1); 2245 tem = make_number (1);
2246 CHECK_NUMBER (tem); 2246 CHECK_NUMBER (tem);
@@ -2262,7 +2262,7 @@ serial_configure (struct Lisp_Process *p,
2262 if (!NILP (Fplist_member (contact, QCflowcontrol))) 2262 if (!NILP (Fplist_member (contact, QCflowcontrol)))
2263 tem = Fplist_get (contact, QCflowcontrol); 2263 tem = Fplist_get (contact, QCflowcontrol);
2264 else 2264 else
2265 tem = Fplist_get (p->childp, QCflowcontrol); 2265 tem = Fplist_get (PVAR (p, childp), QCflowcontrol);
2266 if (!NILP (tem) && !EQ (tem, Qhw) && !EQ (tem, Qsw)) 2266 if (!NILP (tem) && !EQ (tem, Qhw) && !EQ (tem, Qsw))
2267 error (":flowcontrol must be nil (no flowcontrol), `hw', or `sw'"); 2267 error (":flowcontrol must be nil (no flowcontrol), `hw', or `sw'");
2268#if defined (CRTSCTS) 2268#if defined (CRTSCTS)
@@ -2304,7 +2304,7 @@ serial_configure (struct Lisp_Process *p,
2304 error ("tcsetattr() failed: %s", emacs_strerror (errno)); 2304 error ("tcsetattr() failed: %s", emacs_strerror (errno));
2305 2305
2306 childp2 = Fplist_put (childp2, QCsummary, build_string (summary)); 2306 childp2 = Fplist_put (childp2, QCsummary, build_string (summary));
2307 p->childp = childp2; 2307 PVAR (p, childp) = childp2;
2308 2308
2309} 2309}
2310#endif /* not DOS_NT */ 2310#endif /* not DOS_NT */