Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Your suggestion doesn't work on Linux:

  $ echo 'exit 42' >xprog
  $ chmod 755 xprog
  $ python -c 'import os; os.execv("./xprog", ["./xprog"])'; echo $?
  Traceback (most recent call last):
    File "<string>", line 1, in <module>
  OSError: [Errno 8] Exec format error
  1


Consider applying for YC's Winter 2027 batch! Applications are open till November 2.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: