Summary Files Commits Branches @commit @diff @stats
path: root / Year 3 / System programming / Practice03 / ex7-cd.c
blob: ad3b7ecfb2d80743fe028cfb394cb590fad4c855 (plain) (blame)
1
2
3
4
5
6
7
8
9
#include <unistd.h> // chdir
#include <stdio.h> // perror

int main(int argc, char* argv[]) {
	if(chdir(argv[1]) < 0) {
		perror("chdir");
		return 1;
	}
}