I am working on an application (C ++ language on visual studio) where all strings refer to integer pointers.
For example, the class I'm using has this integer pointer to data and a size variable.
{
..
..
unsigned short int *pData;
int iLen
}
I'd like to know
Are there any advantages to using a pointer intinstead of a pointer char?
After thinking a lot, I suspect that the reason may be preventing the application from crashing, which could happen if the char pointer is used without null termination. But I'm not 100% sure.
During debugging, how can we check the contents of a pointer where the contents are an array or a char string (in Visual Studio).
I can only see the address when checking the contents during debugging. Because of this, I have difficulty debugging.
printf , .
, , , , char . 100%.
, , .
, , .
{
..
..
unsigned int * pData;
int iLen
}
, , , .