Re: [PATCH 2/8] Add functions get_relative_cwd() and is_inside_dir() From: Junio C Hamano <hidden> Date: 2016-06-15 22:43:24 Johannes Schindelin [off-list ref] writes: +char *get_relative_cwd(char *buffer, int size, const char *dir) +{ + char *cwd = buffer; + + if (!dir) + return 0; + + if (!getcwd(buffer, PATH_MAX)) + return 0; Can size be less than PATH_MAX?
Keyboard shortcuts hback out one level jnext message in thread kprevious message in thread ldrill in Escclose help / fold thread tree ?toggle this help