Esempio n. 1
0
/* this function should be prefered over file_read_section because it can
 read any file size */
int file_by_name_read_section(const char *file_name, const char *section, xrdpList *names, xrdpList *values)
{
	int fd;
	int file_size;
	int rv;

	file_size = g_file_get_size(file_name);

	if (file_size < 1)
	{
		return 1;
	}

	fd = g_file_open(file_name);

	if (fd < 1)
	{
		return 1;
	}

	rv = l_file_read_section(fd, file_size, section, names, values);
	g_file_close(fd);

	return rv;
}
Esempio n. 2
0
/* 32 K file size limit */
int file_read_section(int fd, const char *section, xrdpList *names, xrdpList *values)
{
	return l_file_read_section(fd, 32 * 1024, section, names, values);
}
Esempio n. 3
0
/* 32 K file size limit */
int APP_CC
file_read_section(int fd, const char *section,
                  struct list *names, struct list *values)
{
    return l_file_read_section(fd, 32 * 1024, section, names, values);
}