>> CopyMemory(&vLines[0], &iLength, sizeof(WORD)+1);
You are copying one to many bytes. Also, you'll want to copy in the same value that was passed to resize() - since that's the size of the buffer.
>> vLines.push_back( '\0' ); //do i need this?
Not like that. EM_GETLINE returns the number of characters copied. Just use "vLines[num_copied] = 0". Your buffer will then be a null-...



