1. <legend id='YpHOD'><style id='YpHOD'><dir id='YpHOD'><q id='YpHOD'></q></dir></style></legend>

        <tfoot id='YpHOD'></tfoot>

        <i id='YpHOD'><tr id='YpHOD'><dt id='YpHOD'><q id='YpHOD'><span id='YpHOD'><b id='YpHOD'><form id='YpHOD'><ins id='YpHOD'></ins><ul id='YpHOD'></ul><sub id='YpHOD'></sub></form><legend id='YpHOD'></legend><bdo id='YpHOD'><pre id='YpHOD'><center id='YpHOD'></center></pre></bdo></b><th id='YpHOD'></th></span></q></dt></tr></i><div id='YpHOD'><tfoot id='YpHOD'></tfoot><dl id='YpHOD'><fieldset id='YpHOD'></fieldset></dl></div>

        • <bdo id='YpHOD'></bdo><ul id='YpHOD'></ul>
      1. <small id='YpHOD'></small><noframes id='YpHOD'>

        Win32 文件被锁定以供阅读:如何找出谁在锁定它们

        时间:2023-07-02
        <i id='ZVj28'><tr id='ZVj28'><dt id='ZVj28'><q id='ZVj28'><span id='ZVj28'><b id='ZVj28'><form id='ZVj28'><ins id='ZVj28'></ins><ul id='ZVj28'></ul><sub id='ZVj28'></sub></form><legend id='ZVj28'></legend><bdo id='ZVj28'><pre id='ZVj28'><center id='ZVj28'></center></pre></bdo></b><th id='ZVj28'></th></span></q></dt></tr></i><div id='ZVj28'><tfoot id='ZVj28'></tfoot><dl id='ZVj28'><fieldset id='ZVj28'></fieldset></dl></div>
            <tbody id='ZVj28'></tbody>

            <bdo id='ZVj28'></bdo><ul id='ZVj28'></ul>

            • <legend id='ZVj28'><style id='ZVj28'><dir id='ZVj28'><q id='ZVj28'></q></dir></style></legend>

              <small id='ZVj28'></small><noframes id='ZVj28'>

                  <tfoot id='ZVj28'></tfoot>
                  本文介绍了Win32 文件被锁定以供阅读:如何找出谁在锁定它们的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  在 C++(特别是 Visual C++)中,有时您无法打开文件,因为另一个可执行文件已将其打开且未共享以供读取.如果我尝试打开这样的文件,我如何以编程方式找出谁锁定了该文件?

                  In C++ (specifically on Visual C++), sometimes you cannot open a file because another executable has it opened and is not sharing it for reads. If I try to open such a file, how can I programatically find out who's locking the file?

                  推荐答案

                  在 Windows 2000 及更高版本中,如果不使用内核模式驱动程序,则无法执行此操作.Process Explorer 和其他类似工具会自动加载驱动程序来完成此操作.这是因为文件句柄位于内核空间中,用户模式应用程序(EXE 文件)无法访问.

                  In Windows 2000 and higher, you cannot do this without using a kernel-mode driver. Process Explorer and other similar tools load a driver automatically to accomplish this. This is because the file handles are in kernel space and not accessible by user-mode applications (EXE files).

                  如果您真的对此感兴趣,请查看this项目.

                  If you are really interested in doing this, take a look at this project.

                  这篇关于Win32 文件被锁定以供阅读:如何找出谁在锁定它们的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:错误:命令“C:\ Visual Studio\2017\Community\VC\Tools\MSVC\14.14.2 下一篇:在 C++ 中执行另一个程序

                  相关文章

                1. <small id='vNl3h'></small><noframes id='vNl3h'>

                      <i id='vNl3h'><tr id='vNl3h'><dt id='vNl3h'><q id='vNl3h'><span id='vNl3h'><b id='vNl3h'><form id='vNl3h'><ins id='vNl3h'></ins><ul id='vNl3h'></ul><sub id='vNl3h'></sub></form><legend id='vNl3h'></legend><bdo id='vNl3h'><pre id='vNl3h'><center id='vNl3h'></center></pre></bdo></b><th id='vNl3h'></th></span></q></dt></tr></i><div id='vNl3h'><tfoot id='vNl3h'></tfoot><dl id='vNl3h'><fieldset id='vNl3h'></fieldset></dl></div>
                      • <bdo id='vNl3h'></bdo><ul id='vNl3h'></ul>
                      <tfoot id='vNl3h'></tfoot>
                    1. <legend id='vNl3h'><style id='vNl3h'><dir id='vNl3h'><q id='vNl3h'></q></dir></style></legend>