コード例 #1
0
ファイル: interp_win32.py プロジェクト: GaussDing/pypy
def CreateNamedPipe(space, name, openmode, pipemode, maxinstances, outputsize, inputsize, timeout, w_security):
    security = space.int_w(w_security)
    if security:
        raise OperationError(space.w_NotImplementedError, space.wrap("expected a NULL pointer"))
    handle = _CreateNamedPipe(name, openmode, pipemode, maxinstances, outputsize, inputsize, timeout, rffi.NULL)

    if handle == rwin32.INVALID_HANDLE_VALUE:
        raise wrap_windowserror(space, rwin32.lastSavedWindowsError())

    return w_handle(space, handle)
コード例 #2
0
def CreateNamedPipe(space, name, openmode, pipemode, maxinstances, outputsize,
                    inputsize, timeout, w_security):
    security = space.int_w(w_security)
    if security:
        raise oefmt(space.w_NotImplementedError, "expected a NULL pointer")
    handle = _CreateNamedPipe(name, openmode, pipemode, maxinstances,
                              outputsize, inputsize, timeout, rffi.NULL)

    if handle == rwin32.INVALID_HANDLE_VALUE:
        raise wrap_windowserror(space, rwin32.lastSavedWindowsError())

    return w_handle(space, handle)
コード例 #3
0
ファイル: interp_win32.py プロジェクト: GaussDing/pypy
def CreateFile(space, filename, access, share, w_security, disposition, flags, w_templatefile):
    security = space.int_w(w_security)
    templatefile = space.int_w(w_templatefile)
    if security or templatefile:
        raise OperationError(space.w_NotImplementedError, space.wrap("expected a NULL pointer"))

    handle = _CreateFile(filename, access, share, rffi.NULL, disposition, flags, rwin32.NULL_HANDLE)

    if handle == rwin32.INVALID_HANDLE_VALUE:
        raise wrap_windowserror(space, rwin32.lastSavedWindowsError())

    return w_handle(space, handle)
コード例 #4
0
def CreateFile(space, filename, access, share, w_security, disposition, flags,
               w_templatefile):
    security = space.int_w(w_security)
    templatefile = space.int_w(w_templatefile)
    if security or templatefile:
        raise oefmt(space.w_NotImplementedError, "expected a NULL pointer")

    handle = _CreateFile(filename, access, share, rffi.NULL, disposition,
                         flags, rwin32.NULL_HANDLE)

    if handle == rwin32.INVALID_HANDLE_VALUE:
        raise wrap_windowserror(space, rwin32.lastSavedWindowsError())

    return w_handle(space, handle)
コード例 #5
0
 def handle_get(self, space):
     return w_handle(space, self.handle)
コード例 #6
0
ファイル: interp_semaphore.py プロジェクト: Darriall/pypy
 def handle_get(self, space):
     return w_handle(space, self.handle)