-
Notifications
You must be signed in to change notification settings - Fork 45
-
Notifications
You must be signed in to change notification settings - Fork 45
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
What if after I created a file I list directory contents? #3
Comments
Like (pseudo code): Print("creating a file..") |
Indeed, the file wouldn't be listed there. I have a rough solution that might solve this (that is return as if the file exists). Anyway, thanks for bringing this to my notice! I'll work on it soon 👍 |
Curious as to what the rough solution is. I'm uninformed, but I would think just creating the path that they asked for as a phantom path in the sandbox would be a good solution. |
So linux uses a sycall called int getdents(unsigned int fd, struct linux_dirent *dirp,
unsigned int count);
Much more difficult than other syscalls indeed. |
@haydenflinner take a look at |
strace was an interesting rabbit hole to go down, thank you!
*Hayden D. Flinner*
Computer Science
Georgia Institute of Technology '18
…On Sun, Jan 29, 2017 at 1:23 PM, Adhityaa Chandrasekar < ***@***.***> wrote:
@haydenflinner <https://github.com/haydenflinner> take a look at man -s 2
getdents to know more. I found this out by running strace ls and looking
at what exactly retrieves the file list :)
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#3 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AOKFbHaSRhpEqX7WGowfKsPgKbQzyawTks5rXNk7gaJpZM4LRGLs>
.
|
|
Sorry, I didn't run your program in real but I suspect that this behavior exists.
The text was updated successfully, but these errors were encountered: