Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit a772075

Browse files
[po] auto sync
1 parent da49615 commit a772075

1 file changed

Lines changed: 24 additions & 5 deletions

File tree

library/os.po

Lines changed: 24 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4648,22 +4648,25 @@ msgid ""
46484648
"Functions registered for execution before forking are called in reverse "
46494649
"registration order. Functions registered for execution after forking "
46504650
"(either in the parent or in the child) are called in registration order."
4651-
msgstr ""
4651+
msgstr "在注册的函数中,用于 fork 前运行的函数将按与注册相反的顺序调用。用于 fork 后(从父进程或子进程)运行的函数按注册顺序调用。"
46524652

46534653
#: /home/travis/build/python/cpython-doc-catalog/Doc/library/os.rst:3706
46544654
msgid ""
46554655
"Note that :c:func:`fork` calls made by third-party C code may not call those"
46564656
" functions, unless it explicitly calls :c:func:`PyOS_BeforeFork`, "
46574657
":c:func:`PyOS_AfterFork_Parent` and :c:func:`PyOS_AfterFork_Child`."
46584658
msgstr ""
4659+
"注意,第三方 C 代码的 :c:func:`fork` 调用可能不会调用这些函数,除非它显式调用了 "
4660+
":c:func:`PyOS_BeforeFork`、:c:func:`PyOS_AfterFork_Parent` 和 "
4661+
":c:func:`PyOS_AfterFork_Child`。"
46594662

46604663
#: /home/travis/build/python/cpython-doc-catalog/Doc/library/os.rst:3710
46614664
msgid "There is no way to unregister a function."
4662-
msgstr ""
4665+
msgstr "函数注册后无法注销。"
46634666

46644667
#: /home/travis/build/python/cpython-doc-catalog/Doc/library/os.rst:3726
46654668
msgid "Execute the program *path* in a new process."
4666-
msgstr ""
4669+
msgstr "在新进程中执行程序 *path*。"
46674670

46684671
#: /home/travis/build/python/cpython-doc-catalog/Doc/library/os.rst:3728
46694672
msgid ""
@@ -4672,6 +4675,8 @@ msgid ""
46724675
"is preferable to using these functions. Check especially the :ref"
46734676
":`subprocess-replacements` section.)"
46744677
msgstr ""
4678+
"(注意,:mod:`subprocess` 模块提供了更强大的工具来生成新进程并跟踪执行结果,使用该模块比使用这些函数更好。尤其应当检查 :ref"
4679+
":`subprocess-replacements` 部分。)"
46754680

46764681
#: /home/travis/build/python/cpython-doc-catalog/Doc/library/os.rst:3733
46774682
msgid ""
@@ -4681,12 +4686,15 @@ msgid ""
46814686
"killed the process. On Windows, the process id will actually be the process"
46824687
" handle, so can be used with the :func:`waitpid` function."
46834688
msgstr ""
4689+
"*mode* 为 :const:`P_NOWAIT` 时,本函数返回新进程的进程号。*mode* 为 :const:`P_WAIT` "
4690+
"时,如果进程正常退出,返回退出代码,如果被终止,返回 ``-signal``,其中 *signal* 是终止进程的信号。在 Windows "
4691+
"上,进程号实际上是进程句柄,因此可以与 :func:`waitpid` 函数一起使用。"
46844692

46854693
#: /home/travis/build/python/cpython-doc-catalog/Doc/library/os.rst:3739
46864694
msgid ""
46874695
"Note on VxWorks, this function doesn't return ``-signal`` when the new "
46884696
"process is killed. Instead it raises OSError exception."
4689-
msgstr ""
4697+
msgstr "注意在 VxWorks 上,新进程被终止时,本函数不会返回 ``-signal``,而是会抛出 OSError 异常。"
46904698

46914699
#: /home/travis/build/python/cpython-doc-catalog/Doc/library/os.rst:3742
46924700
msgid ""
@@ -4715,6 +4723,11 @@ msgid ""
47154723
"not use the :envvar:`PATH` variable to locate the executable; *path* must "
47164724
"contain an appropriate absolute or relative path."
47174725
msgstr ""
4726+
"结尾包含第二个 \"p\" 的变体(:func:`spawnlp`、:func:`spawnlpe`、:func:`spawnvp` 和 "
4727+
":func:`spawnvpe`)将使用 :envvar:`PATH` 环境变量来查找程序 *file*。当环境被替换时(使用下一段讨论的 "
4728+
":func:`spawn\\*e <spawnl>` 变体之一),:envvar:`PATH` 变量将来自于新环境。其他变体 "
4729+
":func:`spawnl`、:func:`spawnle`、:func:`spawnv` 和 :func:`spawnve` 不使用 "
4730+
":envvar:`PATH` 变量来查找程序,因此 *path* 必须包含正确的绝对或相对路径。"
47184731

47194732
#: /home/travis/build/python/cpython-doc-catalog/Doc/library/os.rst:3761
47204733
msgid ""
@@ -4728,18 +4741,24 @@ msgid ""
47284741
"keys or values will cause the function to fail, with a return value of "
47294742
"``127``."
47304743
msgstr ""
4744+
"对于 :func:`spawnle`、:func:`spawnlpe`、:func:`spawnve` 和 :func:`spawnvpe` (都以 "
4745+
"\"e\" 结尾),*env* 参数是一个映射,用于定义新进程的环境变量(代替当前进程的环境变量)。而函数 "
4746+
":func:`spawnl`、:func:`spawnlp`、:func:`spawnv` 和 :func:`spawnvp` "
4747+
"会将当前进程的环境变量过继给新进程。注意,*env* 字典中的键和值必须是字符串。无效的键或值将导致函数出错,返回值为 ``127``。"
47314748

47324749
#: /home/travis/build/python/cpython-doc-catalog/Doc/library/os.rst:3770
47334750
msgid ""
47344751
"As an example, the following calls to :func:`spawnlp` and :func:`spawnvpe` "
47354752
"are equivalent::"
4736-
msgstr ""
4753+
msgstr "例如,以下对 :func:`spawnlp` 和 :func:`spawnvpe` 的调用是等效的::"
47374754

47384755
#: /home/travis/build/python/cpython-doc-catalog/Doc/library/os.rst:3780
47394756
msgid ""
47404757
"Raises an :ref:`auditing event <auditing>` ``os.spawn`` with arguments "
47414758
"``mode``, ``path``, ``args``, ``env``."
47424759
msgstr ""
4760+
"引发一个 :ref:`审计事件 <auditing>` ``os.spawn``,附带参数 "
4761+
"``mode``、``path``、``args``、``env``。"
47434762

47444763
#: /home/travis/build/python/cpython-doc-catalog/Doc/library/os.rst:3785
47454764
msgid ""

0 commit comments

Comments
 (0)