Mercurial > hg > xemacs-beta
comparison src/ntproc.c @ 380:8626e4521993 r21-2-5
Import from CVS: tag r21-2-5
author | cvs |
---|---|
date | Mon, 13 Aug 2007 11:07:10 +0200 |
parents | 6240c7796c7a |
children | 74fd4e045ea6 |
comparison
equal
deleted
inserted
replaced
379:76b7d63099ad | 380:8626e4521993 |
---|---|
56 /* #### I'm not going to play with shit. */ | 56 /* #### I'm not going to play with shit. */ |
57 #pragma warning (disable:4013 4024 4090) | 57 #pragma warning (disable:4013 4024 4090) |
58 | 58 |
59 /* Control whether spawnve quotes arguments as necessary to ensure | 59 /* Control whether spawnve quotes arguments as necessary to ensure |
60 correct parsing by child process. Because not all uses of spawnve | 60 correct parsing by child process. Because not all uses of spawnve |
61 are careful about constructing argv arrays, we make this behaviour | 61 are careful about constructing argv arrays, we make this behavior |
62 conditional (off by default). */ | 62 conditional (off by default). */ |
63 Lisp_Object Vwin32_quote_process_args; | 63 Lisp_Object Vwin32_quote_process_args; |
64 | 64 |
65 /* Control whether create_child causes the process' window to be | 65 /* Control whether create_child causes the process' window to be |
66 hidden. The default is nil. */ | 66 hidden. The default is nil. */ |
618 exactly, so we treat quotes at the beginning and end of arguments | 618 exactly, so we treat quotes at the beginning and end of arguments |
619 as embedded quotes. | 619 as embedded quotes. |
620 | 620 |
621 The Win32 GNU-based library from Cygnus doubles quotes to escape | 621 The Win32 GNU-based library from Cygnus doubles quotes to escape |
622 them, while MSVC uses backslash for escaping. (Actually the MSVC | 622 them, while MSVC uses backslash for escaping. (Actually the MSVC |
623 startup code does attempt to recognise doubled quotes and accept | 623 startup code does attempt to recognize doubled quotes and accept |
624 them, but gets it wrong and ends up requiring three quotes to get a | 624 them, but gets it wrong and ends up requiring three quotes to get a |
625 single embedded quote!) So by default we decide whether to use | 625 single embedded quote!) So by default we decide whether to use |
626 quote or backslash as the escape character based on whether the | 626 quote or backslash as the escape character based on whether the |
627 binary is apparently a Cygnus compiled app. | 627 binary is apparently a Cygnus compiled app. |
628 | 628 |
629 Note that using backslash to escape embedded quotes requires | 629 Note that using backslash to escape embedded quotes requires |
630 additional special handling if an embedded quote is already | 630 additional special handling if an embedded quote is already |
631 preceeded by backslash, or if an arg requiring quoting ends with | 631 preceded by backslash, or if an arg requiring quoting ends with |
632 backslash. In such cases, the run of escape characters needs to be | 632 backslash. In such cases, the run of escape characters needs to be |
633 doubled. For consistency, we apply this special handling as long | 633 doubled. For consistency, we apply this special handling as long |
634 as the escape character is not quote. | 634 as the escape character is not quote. |
635 | 635 |
636 Since we have no idea how large argv and envp are likely to be we | 636 Since we have no idea how large argv and envp are likely to be we |
722 last = p + strlen (p) - 1; | 722 last = p + strlen (p) - 1; |
723 *parg++ = '"'; | 723 *parg++ = '"'; |
724 #if 0 | 724 #if 0 |
725 /* This version does not escape quotes if they occur at the | 725 /* This version does not escape quotes if they occur at the |
726 beginning or end of the arg - this could lead to incorrect | 726 beginning or end of the arg - this could lead to incorrect |
727 behaviour when the arg itself represents a command line | 727 behavior when the arg itself represents a command line |
728 containing quoted args. I believe this was originally done | 728 containing quoted args. I believe this was originally done |
729 as a hack to make some things work, before | 729 as a hack to make some things work, before |
730 `win32-quote-process-args' was added. */ | 730 `win32-quote-process-args' was added. */ |
731 while (*p) | 731 while (*p) |
732 { | 732 { |
1191 | 1191 |
1192 | 1192 |
1193 DEFUN ("win32-get-locale-info", Fwin32_get_locale_info, 1, 2, "", /* | 1193 DEFUN ("win32-get-locale-info", Fwin32_get_locale_info, 1, 2, "", /* |
1194 "Return information about the Windows locale LCID. | 1194 "Return information about the Windows locale LCID. |
1195 By default, return a three letter locale code which encodes the default | 1195 By default, return a three letter locale code which encodes the default |
1196 language as the first two characters, and the country or regionial variant | 1196 language as the first two characters, and the country or regional variant |
1197 as the third letter. For example, ENU refers to `English (United States)', | 1197 as the third letter. For example, ENU refers to `English (United States)', |
1198 while ENC means `English (Canadian)'. | 1198 while ENC means `English (Canadian)'. |
1199 | 1199 |
1200 If the optional argument LONGFORM is non-nil, the long form of the locale | 1200 If the optional argument LONGFORM is non-nil, the long form of the locale |
1201 name is returned, e.g. `English (United States)' instead. | 1201 name is returned, e.g. `English (United States)' instead. |
1393 #if 0 | 1393 #if 0 |
1394 DEFVAR_LISP ("win32-generate-fake-inodes", &Vwin32_generate_fake_inodes /* | 1394 DEFVAR_LISP ("win32-generate-fake-inodes", &Vwin32_generate_fake_inodes /* |
1395 "Non-nil means attempt to fake realistic inode values. | 1395 "Non-nil means attempt to fake realistic inode values. |
1396 This works by hashing the truename of files, and should detect | 1396 This works by hashing the truename of files, and should detect |
1397 aliasing between long and short (8.3 DOS) names, but can have | 1397 aliasing between long and short (8.3 DOS) names, but can have |
1398 false positives because of hash collisions. Note that determing | 1398 false positives because of hash collisions. Note that determining |
1399 the truename of a file can be slow. | 1399 the truename of a file can be slow. |
1400 */ ); | 1400 */ ); |
1401 Vwin32_generate_fake_inodes = Qnil; | 1401 Vwin32_generate_fake_inodes = Qnil; |
1402 #endif | 1402 #endif |
1403 } | 1403 } |