Bug 212

Summary: res_init(3) is undocumented
Product: glibc Reporter: Petter Reinholdtsen <pere>
Component: manualAssignee: Roland McGrath <roland>
Status: NEW ---    
Severity: normal CC: carlos, glibc-bugs
Priority: P2    
Version: unspecified   
Target Milestone: ---   
Host: Target:
Build: Last reconfirmed: 2010-06-01 02:02:14
Attachments: patch documents the remquo functions

Description Petter Reinholdtsen 2004-06-10 10:09:45 UTC
The function used to rescan /etc/resolv.conf is not mentioned in the manual.
It would be nice it was documented in the official glibc documentation.

It is documented in the manpages package.
Comment 1 Roland McGrath 2006-02-22 06:55:00 UTC
We welcome your contribution of new wording for the manual.
Comment 2 Dwayne Grant McConnell 2006-02-28 19:33:28 UTC
Do you have a suggested wording for this documentation?
Comment 3 Petter Reinholdtsen 2006-03-02 16:04:00 UTC
Not really.  I just noted the lack of documententation and wanted to make
sure it wasn't forgotten.

Not sure if it is OK to just copy from the manual page.  There it is
documented like this along with several of the res_* functions.

       #include <netinet/in.h>
       #include <arpa/nameser.h>
       #include <resolv.h>
       extern struct state _res;

       int res_init(void);
       The res_init() function reads the configuration files (see resolv+(8))
       to  get  the  default  domain  name,  search  order  and  name  server
       address(es).   If  no server is given, the local host is tried.  If no
       domain is given, that associated with the local host is used.  It  can
       be  overridden  with the environment variable LOCALDOMAIN.  res_init()
       is normally executed by the first call to one of the other  functions.
Comment 4 Shaun 2007-11-24 12:11:50 UTC
Created attachment 2106 [details]
patch documents the remquo functions
Comment 5 Shaun 2007-11-24 12:18:05 UTC
Comment on attachment 2106 [details]
patch documents the remquo functions

--- manual/arith.texi	2007-11-19 12:00:50.000000000 +1100
+++ arith.texi	2007-11-24 23:03:06.000000000 +1100
@@ -1546,6 +1546,29 @@
 This function is another name for @code{drem}.
 @end deftypefun

+@comment math.h
+@comment ISO_C99
+@deftypefun double remquo (double @var{numerator}, double @var{denominator},
int @var{*quo})
+@comment math.h
+@comment ISO_C99
+@deftypefunx float remquof (float @var{numerator}, float @var{denominator},
int @var{*quo})
+@comment math.h
+@comment ISO_C99
+@deftypefunx {long double} remquol (long double @var{numerator}, long double
@var{denominator}, int @var{*quo})
+These	functions  compute the remainder and part of the quotient upon division
+of @var{numerator} by @var{denominator}. A few bits of the quotient are stored
+via the @var{quo} pointer. The remainder is returned as function value.
+The value of the remainder is the same as that computed by the
+function above. The value stored via the @var{quo} pointer has the sign of
+@var{numerator}/@var{denominator} and agrees with the quotient in at least the
+low order 3 bits.
+For example, @code{remquo(29.0,3.0)} returns @code{-1.0} and might store
+Note that the actual quotient might not fit in an integer.
+@end deftypefun
 @node FP Bit Twiddling
 @subsection Setting and modifying single bits of FP values
 @cindex FP arithmetic
Comment 6 Shaun 2007-11-24 12:40:02 UTC
Comment on attachment 2106 [details]
patch documents the remquo functions

this is a mistake, this patch addresses bug 4449, it also should have the first
3 leading '/' removed from the patch. Shaun
Comment 7 Petr Baudis 2010-06-01 02:02:14 UTC
info provided