Copy Flash video from cache
Use,
$ stat -c %N /proc/*/fd/* | grep Flash
to find the deleted file descriptor, then copy with cp.
Use,
$ stat -c %N /proc/*/fd/* | grep Flash
to find the deleted file descriptor, then copy with cp.
"Client",
$ nc -l -p <port> -q 2
and "Server",
$ cat <file> | nc <host> <port>
To watch progress on client,
$ watch 'ls -lrt | tail'
location ~ ^/~(.+?)(/.*)?$ {
alias /home/$1/public_html$2;
index index.html index.htm;
autoindex on;
}
This snippet in C counts tokens that will be found with strtok(3).
int tokcnt(const char *s, const char *delim)
{
int n = 0;
while (*s)
if (strchr(delim, *s++) == NULL) {
++n;
while (strchr(delim, *s) == NULL)
++s;
}
return n;
}