aboutsummaryrefslogtreecommitdiffstats
path: root/src/process.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/process.c')
-rw-r--r--src/process.c16
1 files changed, 14 insertions, 2 deletions
diff --git a/src/process.c b/src/process.c
index 4f6d2832f8d..14535eb6e1e 100644
--- a/src/process.c
+++ b/src/process.c
@@ -1295,7 +1295,20 @@ Returns nil if format of ADDRESS is invalid. */)
1295 return Qnil; 1295 return Qnil;
1296 1296
1297 for (i = 0; i < nargs; i++) 1297 for (i = 0; i < nargs; i++)
1298 args[i+1] = p->contents[i]; 1298 {
1299 EMACS_INT element = XINT (p->contents[i]);
1300
1301 if (element < 0 || element > 65535)
1302 return Qnil;
1303
1304 if (nargs <= 5 /* IPv4 */
1305 && i < 4 /* host, not port */
1306 && element > 255)
1307 return Qnil;
1308
1309 args[i+1] = p->contents[i];
1310 }
1311
1299 return Fformat (nargs+1, args); 1312 return Fformat (nargs+1, args);
1300 } 1313 }
1301 1314
@@ -1410,7 +1423,6 @@ list_processes_1 (query_only)
1410 if (CONSP (p->status)) 1423 if (CONSP (p->status))
1411 symbol = XCAR (p->status); 1424 symbol = XCAR (p->status);
1412 1425
1413
1414 if (EQ (symbol, Qsignal)) 1426 if (EQ (symbol, Qsignal))
1415 { 1427 {
1416 Lisp_Object tem; 1428 Lisp_Object tem;