File:  [DVB] / dietlibc / lib / getauxval.c
Revision 1.1: download - view: text, annotated - select for diffs
Sat Sep 29 16:28:56 2018 UTC (5 years, 8 months ago) by leitner
Branches: MAIN
CVS tags: HEAD
pie fixes

#include <stdio.h>
#include <sys/auxv.h>

static void* find_in_auxvec(long* x,long what) {
  while (*x) {
    if (*x==what)
      return (void*)x[1];
    x+=2;
  }
  return NULL;
}

long* _auxvec;

unsigned long getauxval(unsigned long type) {
  return (long)find_in_auxvec(_auxvec,type);
}


LinuxTV legacy CVS <linuxtv.org/cvs>