Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 119 for Getcwd (0.23 sec)

  1. src/runtime/testdata/testprog/syscalls_linux.go

    }
    
    func getcwd() (string, error) {
    	if !syscall.ImplementsGetwd {
    		return "", nil
    	}
    	// Use the syscall to get the current working directory.
    	// This is imperative for checking for OS thread state
    	// after an unshare since os.Getwd might just check the
    	// environment, or use some other mechanism.
    	var buf [4096]byte
    	n, err := syscall.Getcwd(buf[:])
    	if err != nil {
    		return "", err
    	}
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 21 20:00:09 UTC 2024
    - 2.2K bytes
    - Viewed (0)
  2. src/runtime/testdata/testprog/syscalls_none.go

    //go:build !linux
    // +build !linux
    
    package main
    
    func gettid() int {
    	return 0
    }
    
    func tidExists(tid int) (exists, supported bool, err error) {
    	return false, false, nil
    }
    
    func getcwd() (string, error) {
    	return "", nil
    }
    
    func unshareFs() error {
    	return nil
    }
    
    func chdir(path string) error {
    	return nil
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 21 20:00:09 UTC 2024
    - 471 bytes
    - Viewed (0)
  3. tests/test_tutorial/test_custom_docs_ui/test_tutorial002.py

    import os
    from pathlib import Path
    
    import pytest
    from fastapi.testclient import TestClient
    
    
    @pytest.fixture(scope="module")
    def client():
        static_dir: Path = Path(os.getcwd()) / "static"
        print(static_dir)
        static_dir.mkdir(exist_ok=True)
        from docs_src.custom_docs_ui.tutorial002 import app
    
        with TestClient(app) as client:
            yield client
        static_dir.rmdir()
    
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Sat Aug 19 19:54:04 UTC 2023
    - 1.2K bytes
    - Viewed (0)
  4. tests/test_tutorial/test_custom_docs_ui/test_tutorial001.py

    import os
    from pathlib import Path
    
    import pytest
    from fastapi.testclient import TestClient
    
    
    @pytest.fixture(scope="module")
    def client():
        static_dir: Path = Path(os.getcwd()) / "static"
        print(static_dir)
        static_dir.mkdir(exist_ok=True)
        from docs_src.custom_docs_ui.tutorial001 import app
    
        with TestClient(app) as client:
            yield client
        static_dir.rmdir()
    
    
    Registered: Mon Jun 17 08:32:26 UTC 2024
    - Last Modified: Thu May 23 22:59:02 UTC 2024
    - 1.3K bytes
    - Viewed (0)
  5. src/syscall/syscall_openbsd1.go

    //go:build openbsd && mips64
    
    package syscall
    
    //sys	readlen(fd int, buf *byte, nbuf int) (n int, err error) = SYS_READ
    //sys	Seek(fd int, offset int64, whence int) (newoffset int64, err error) = SYS_LSEEK
    //sys	getcwd(buf []byte) (n int, err error) = SYS___GETCWD
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Sep 20 18:12:35 UTC 2023
    - 534 bytes
    - Viewed (0)
  6. src/runtime/testdata/testprog/lockosthread.go

    	// from a clean thread. Cloning from a locked thread is undesirable since
    	// cloned threads will inherit potentially unwanted OS state.
    	//
    	// unshareFs, getcwd, and chdir("/tmp") are only guaranteed to work on
    	// Linux, so on other platforms this just checks that the runtime doesn't
    	// do anything terrible.
    	//
    	// This is running locked to the main OS thread.
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Thu Mar 21 20:00:09 UTC 2024
    - 6.6K bytes
    - Viewed (0)
  7. src/syscall/syscall_openbsd_libc.go

    }
    
    //sys	readlen(fd int, buf *byte, nbuf int) (n int, err error) = SYS_read
    //sys	Seek(fd int, offset int64, whence int) (newoffset int64, err error) = SYS_lseek
    //sys	getcwd(buf []byte) (n int, err error)
    //sys	sysctl(mib []_C_int, old *byte, oldlen *uintptr, new *byte, newlen uintptr) (err error)
    //sysnb fork() (pid int, err error)
    //sysnb execve(path *byte, argv **byte, envp **byte) (err error)
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Sat May 04 07:51:20 UTC 2024
    - 3.7K bytes
    - Viewed (0)
  8. src/runtime/runtime-lldb_test.go

    if target:
      print "Created target"
      main_bp = target.BreakpointCreateByLocation("main.go", 10)
      if main_bp:
        print "Created breakpoint"
      process = target.LaunchSimple(None, None, os.getcwd())
      if process:
        print "Process launched"
        listener = debugger.GetListener()
        process.broadcaster.AddListener(listener, lldb.SBProcess.eBroadcastBitStateChanged)
        while True:
          event = lldb.SBEvent()
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Feb 21 22:16:54 UTC 2024
    - 4.8K bytes
    - Viewed (0)
  9. src/syscall/syscall_js.go

    }
    
    func Sysctl(key string) (string, error) {
    	if key == "kern.hostname" {
    		return "js", nil
    	}
    	return "", ENOSYS
    }
    
    const ImplementsGetwd = true
    
    func Getwd() (wd string, err error) {
    	var buf [PathMax]byte
    	n, err := Getcwd(buf[0:])
    	if err != nil {
    		return "", err
    	}
    	return string(buf[:n]), nil
    }
    
    func Getuid() int {
    	return jsProcess.Call("getuid").Int()
    }
    
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Feb 26 21:03:59 UTC 2024
    - 6.7K bytes
    - Viewed (0)
  10. src/syscall/syscall_netbsd.go

    //sys	munmap(addr uintptr, length uintptr) (err error)
    //sys	readlen(fd int, buf *byte, nbuf int) (n int, err error) = SYS_READ
    //sys	utimensat(dirfd int, path string, times *[2]Timespec, flag int) (err error)
    //sys	getcwd(buf []byte) (n int, err error) = SYS___GETCWD
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Wed Sep 20 18:12:35 UTC 2023
    - 7.8K bytes
    - Viewed (0)
Back to top