the "dir" parameter contains the name of the directory, while the "dirh"
variable is an opendir() handle that'll only be NULL in case of error.
By complete accident, this compiled, but it wouldn't actually ever do
anything useful.
GArray* tmp;
struct stat stbuf;
- if(!dir) {
+ if(!dirh) {
g_set_error(e, NBDS_ERR, NBDS_ERR_CFILE_DIR_UNKNOWN, "Invalid directory specified: %s", strerror(errno));
return NULL;
}