strlen-like function for pointers? ptrlen?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi there.

Is there a strlen-like function for pointers? I have this code:

struct ts_filter_api **api_r = api;
int count = 0;
/* find out how many filters we need to create */
while (*api_r) {
  count++;
  api_r++;
}

and I would like to have it replaced with

ptrlen(api);

If it doesn't exist -- do you see something that could go wrong with a
ptrlen function? Would upstream like it?

--
To unsubscribe from this list: send an email with
"unsubscribe kernelnewbies" to ecartis@xxxxxxxxxxxx
Please read the FAQ at http://kernelnewbies.org/FAQ


[Index of Archives]     [Newbies FAQ]     [Linux Kernel Mentors]     [Linux Kernel Development]     [IETF Annouce]     [Git]     [Networking]     [Security]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux SCSI]     [Linux ACPI]
  Powered by Linux