I am trying to redesign the API of my previous project that I've worked on it, which was written in C, in a way that it can be used in an application written in C++ language.
I was using in C language lseek()
for chasing table, pages etc.
My question is, Is it okay to still use lseek()
in C++ the way that I have used it, like a sample code below:
/* Read page data from an offset. It assumes that pagenum is zero-indexed*/
lseek(bq.unixfd, PAGE_SIZE + (PAGE_SIZE * bq.pagenum), SEEK_SET);
thanks alot