r398: * update release notes
[Samba.git] / source / aparser / util.awk
blob6c5594da688bf53c45deb4096cede169c8cce883
1 function isaptr(elem)
3 if (substr(elem, 1, 1) == "*") {
4 return 1;
6 return 0;
9 function noptr(elem)
11 if (!isaptr(elem)) return elem;
12 return substr(elem, 2);
15 function xprintf(f, fmt, v1, v2, v3, v4, v5, v6, v7)
17 printf(fmt, v1, v2, v3, v4, v5, v6) > f;
20 function fatal(why)
22 printf("FATAL: %s\n", why);
23 exit 1;
26 function numlines(fname,
27 LOCAL, line, count)
29 count=0;
30 while ((getline line < fname) > 0) count++;
31 close(fname);
32 return count;
35 # return 1 if the string is a constant
36 function is_constant(s)
38 return match(s,"^[0-9]+$");