私は小さな問題に遭遇し、助けが必要です:
文字の割り当てられたバッファーがあり、このバッファー内のどこかに始点と終点があり、これらの 2 つの点の間の長さが必要な場合、どうすればそれを見つけることができますか?
すなわち
char * buf; //malloc of 100 chars
char * start; // some point in buff
char * end; // some point after start in buf
int length = &end-&start? or &start-&end?
//How to grab the length between these two points.
ありがとう