Пример #1
0
static void wf_cliprdr_add_to_file_arrays(wfClipboard* clipboard, WCHAR* full_file_name, int pathLen)
{
	/* add to name array */
	clipboard->file_names[clipboard->nFiles] = (LPWSTR) malloc(MAX_PATH * 2);
	wcscpy_s(clipboard->file_names[clipboard->nFiles], MAX_PATH, full_file_name);

	/* add to descriptor array */
	clipboard->fileDescriptor[clipboard->nFiles] = wf_cliprdr_get_file_descriptor(full_file_name, pathLen);

	clipboard->nFiles++;

	wf_cliprdr_array_ensure_capacity(clipboard);
}
Пример #2
0
static void wf_cliprdr_add_to_file_arrays(cliprdrContext *cliprdr, WCHAR *full_file_name, int pathLen)
{
	/* add to name array */
	cliprdr->file_names[cliprdr->nFiles] = (LPWSTR)malloc(MAX_PATH);
	wcscpy(cliprdr->file_names[cliprdr->nFiles], full_file_name);

	/* add to descriptor array */
	cliprdr->fileDescriptor[cliprdr->nFiles] = wf_cliprdr_get_file_descriptor(full_file_name, pathLen);

	cliprdr->nFiles++;

	wf_cliprdr_array_ensure_capacity(cliprdr);
}