[patch] Don't append extra NUL to registry-strings.

Bas van Gompel cygwin-patches.buzz@bavag.tmfweb.nl
Sun Sep 4 03:06:00 GMT 2005


Op Mon, 29 Aug 2005 10:21:19 +0200 schreef Corinna Vinschen
in <20050829082119.GA24845@calimero.vinschen.de>:
:  On Aug 28 22:49, Bas van Gompel wrote:
: > Hi,
: >
: > When RegQueryValueEx returns a string-type, the final NUL is included
: > in the returned size. I suggest dropping it.
:
:  I see what you're up to, but there would be two reasons not to drop the
:  trailing \0.  First, the \0 is part of the "file content" in a way.  

Don't file-systems have their own way of reporting ends (EOF)?

:  Second, it would break backward compatibility with applications using
:  /proc/registry.  This latter point concerns me a bit, though it can
:  naturally only affect Cygwin applications.

Hmmm... :( ... possibly the CYGWIN-environment-variable might have room
for something like ``registry:raw,data'' (default, for  now) to mean
``as is'', and other options might cause various levels of verbosity/
interpretation... (I know SHTDI, but would P be TC for such a thing?)


L8r,
-- 
  ) |  | ---/ ---/  Yes, this | This message consists of true | I do not
--  |  |   /    /   really is |   and false bits entirely.    | mail for
  ) |  |  /    /    a 72 by 4 +-------------------------------+ any1 but
--  \--| /--- /---  .sigfile. |   |perl -pe "s.u(z)\1.as."    | me. 4^re



More information about the Cygwin-patches mailing list