OSSP CVS Repository

ossp - Check-in [4644]
Not logged in
[Honeypot]  [Browse]  [Home]  [Login]  [Reports
[Search]  [Ticket]  [Timeline
  [Patchset]  [Tagging/Branching

Check-in Number: 4644
Date: 2004-Jul-16 23:04:30 (local)
2004-Jul-16 21:04:30 (UTC)
User:rse
Branch:
Comment: Made documentation of uuid_export() more clear.
Tickets:
Inspections:
Files:
ossp-pkg/uuid/ChangeLog      1.49 -> 1.50     4 inserted, 1 deleted
ossp-pkg/uuid/uuid.pod      1.17 -> 1.18     12 inserted, 8 deleted

ossp-pkg/uuid/ChangeLog 1.49 -> 1.50

--- ChangeLog    2004/06/09 19:19:33     1.49
+++ ChangeLog    2004/07/16 21:04:30     1.50
@@ -11,7 +11,10 @@
   This is a list of all changes to OSSP uuid.
   For a more brief summary please have a look at the NEWS file.
 
-  Changes between 1.0.0 and 1.0.1 (16-Feb-2004 to xx-Jun-2004)
+  Changes between 1.0.0 and 1.0.1 (16-Feb-2004 to 16-Jul-2004)
+
+   o Made documentation of uuid_export() more clear.
+     [Ralf S. Engelschall]
 
    o Upgrade build environment to GNU libtool 1.5.6
      [Ralf S. Engelschall]


ossp-pkg/uuid/uuid.pod 1.17 -> 1.18

--- uuid.pod     2004/06/09 19:18:25     1.17
+++ uuid.pod     2004/07/16 21:04:30     1.18
@@ -263,11 +263,13 @@
 =item uuid_rc_t B<uuid_export>(uuid_t *I<uuid>, uuid_fmt_t I<fmt>, void **I<data_ptr>, size_t *I<data_len>);
 
 Exports a UUID I<uuid> into an external representation of format I<fmt>.
-The data is written to the buffer at C<*>I<data_ptr> which has room
-for at least C<*>I<data_len> bytes. If C<*>I<data_ptr> is C<NULL>,
-a new buffer is allocated (and I<data_len> ignored as input). If
-I<data_len> is not C<NULL>, the number of written bytes are stored into
-C<*>I<data_len>.
+The data is written to the buffer at C<*>I<data_ptr> which has to
+be room for at least C<*>I<data_len> bytes. If C<*>I<data_ptr> is
+C<NULL>, I<data_len> is ignored as input and a new buffer is allocated
+and returned in C<*>I<data_ptr> (the caller has to free(3) it later
+on). If I<data_len> is not C<NULL>, the number of available bytes at
+C<*>I<data_ptr> has to be provided in C<*>I<data_len> and the number of
+actually written bytes are returned in C<*>I<data_len> again.
 
 The format of the external representation is specified by I<fmt> and the
 minimum required length in C<*>I<data_len> depends on it. Valid values
@@ -344,10 +346,11 @@
  char *uuid_v1(void)
  {
      uuid_t *uuid;
-     char *str = NULL;
+     char *str;
 
      uuid_create(&uuid);
      uuid_make(uuid, UUID_MAKE_V1);
+     str = NULL;
      uuid_export(uuid, UUID_FMT_STR, (void **)&str, NULL);
      uuid_destroy(uuid);
      return str;
@@ -358,12 +361,13 @@
  {
      uuid_t *uuid;
      uuid_t *uuid_ns;
-     char *str = NULL;
+     char *str;
 
      uuid_create(&uuid);
      uuid_create(&uuid_ns);
      uuid_load(uuid_ns, "ns:URL");
      uuid_make(uuid, UUID_MAKE_V3, uuid_ns, url);
+     str = NULL;
      uuid_export(uuid, UUID_FMT_STR, (void **)&str, NULL);
      uuid_destroy(uuid_ns);
      uuid_destroy(uuid);
@@ -372,7 +376,7 @@
 
 =head1 SEE ALSO
 
-See the following are references to more B<UUID> documentation and specifications:
+The following are references to B<UUID> documentation and specifications:
 
 =over 4
 

CVSTrac 2.0.1