<feed xmlns='http://www.w3.org/2005/Atom'>
<title>u-boot.git/lib/hashtable.c, branch v2016.03</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.
</subtitle>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/'/>
<entry>
<title>env: import: hashtable: Free memory allocated before exiting from himport_r()</title>
<updated>2015-09-15T19:05:13+00:00</updated>
<author>
<name>Lukasz Majewski</name>
<email>l.majewski@majess.pl</email>
</author>
<published>2015-09-13T22:57:04+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=0226d8780b3886a4acdd2d4c9731419306d470f6'/>
<id>0226d8780b3886a4acdd2d4c9731419306d470f6</id>
<content type='text'>
ithout this patch memory is not released on early exit.

Signed-off-by: Lukasz Majewski &lt;l.majewski@majess.pl&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
ithout this patch memory is not released on early exit.

Signed-off-by: Lukasz Majewski &lt;l.majewski@majess.pl&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>env: import: hashtable: Prevent buffer overrun when importing environment from file</title>
<updated>2015-09-15T19:05:08+00:00</updated>
<author>
<name>Lukasz Majewski</name>
<email>l.majewski@majess.pl</email>
</author>
<published>2015-09-13T22:57:03+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=817e48d8a2998b19dc36a77f8363b5f74bc3fa9e'/>
<id>817e48d8a2998b19dc36a77f8363b5f74bc3fa9e</id>
<content type='text'>
Lets consider following scenario:
- One uses echo -n "key=value" to define environment variable in a file (single variable)
- The file content is "key=value" without any terminating byte (e.g. 0x0a or
0x0d).
- The file is loaded to u-boot non zero'ed RAM buffer (with load command).
- Then "env import -t -r $loadaddr $filesize" is executed.
- Due to lack of proper termination byte we have classical example of buffer
  overrun.

This patch prevents from this by allocating one extra byte than size and
explicitly null terminate it.

There should be no change for normal env import operation after applying
this patch.

Signed-off-by: Lukasz Majewski &lt;l.majewski@majess.pl&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Lets consider following scenario:
- One uses echo -n "key=value" to define environment variable in a file (single variable)
- The file content is "key=value" without any terminating byte (e.g. 0x0a or
0x0d).
- The file is loaded to u-boot non zero'ed RAM buffer (with load command).
- Then "env import -t -r $loadaddr $filesize" is executed.
- Due to lack of proper termination byte we have classical example of buffer
  overrun.

This patch prevents from this by allocating one extra byte than size and
explicitly null terminate it.

There should be no change for normal env import operation after applying
this patch.

Signed-off-by: Lukasz Majewski &lt;l.majewski@majess.pl&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Add option -r to env import to allow import of text files with CRLF as line endings</title>
<updated>2014-07-22T11:44:26+00:00</updated>
<author>
<name>Alexander Holler</name>
<email>holler@ahsoftware.de</email>
</author>
<published>2014-07-14T15:49:55+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=ecd1446fe1df00d7f7b9de286dba309d93b51870'/>
<id>ecd1446fe1df00d7f7b9de286dba309d93b51870</id>
<content type='text'>
When this option is enabled, CRLF is treated like LF when importing environments
from text files, which means CRs ('\r') in front of LFs ('\n') are just ignored.

Drawback of enabling this option is that (maybe exported) variables which have
a trailing CR in their content will get imported without that CR. But this
drawback is very unlikely and the big advantage of letting Windows user create
a *working* uEnv.txt too is likely more welcome.

Signed-off-by: Alexander Holler &lt;holler@ahsoftware.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When this option is enabled, CRLF is treated like LF when importing environments
from text files, which means CRs ('\r') in front of LFs ('\n') are just ignored.

Drawback of enabling this option is that (maybe exported) variables which have
a trailing CR in their content will get imported without that CR. But this
drawback is very unlikely and the big advantage of letting Windows user create
a *working* uEnv.txt too is likely more welcome.

Signed-off-by: Alexander Holler &lt;holler@ahsoftware.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>env: fix the env export varname</title>
<updated>2013-11-08T20:25:14+00:00</updated>
<author>
<name>Pierre Aubert</name>
<email>p.aubert@staubli.com</email>
</author>
<published>2013-10-08T12:20:27+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=9a8323311ca500579b86905fcf539f17c193ce25'/>
<id>9a8323311ca500579b86905fcf539f17c193ce25</id>
<content type='text'>
The env export command doesn't export the first variable of the list
since commit 5a31ea04c9ee5544fbb70ad7597ea4b294840eab
"env grep" - reimplement command using hexport_r()

Signed-off-by: Pierre Aubert &lt;p.aubert@staubli.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The env export command doesn't export the first variable of the list
since commit 5a31ea04c9ee5544fbb70ad7597ea4b294840eab
"env grep" - reimplement command using hexport_r()

Signed-off-by: Pierre Aubert &lt;p.aubert@staubli.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Cosmetic: Fix a number of typos, no functional changes.</title>
<updated>2013-09-20T14:30:54+00:00</updated>
<author>
<name>Robert P. J. Day</name>
<email>rpjday@crashcourse.ca</email>
</author>
<published>2013-09-16T11:15:45+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=1bce2aeb6f31043caa0509387d85b786c1d2e147'/>
<id>1bce2aeb6f31043caa0509387d85b786c1d2e147</id>
<content type='text'>
Fix various misspellings of things like "environment", "kernel",
"default" and "volatile", and throw in a couple grammar fixes.

Signed-off-by: Robert P. J. Day &lt;rpjday@crashcourse.ca&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix various misspellings of things like "environment", "kernel",
"default" and "volatile", and throw in a couple grammar fixes.

Signed-off-by: Robert P. J. Day &lt;rpjday@crashcourse.ca&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Add LGPL-2.1+ SPDX-License-Identifier to source files</title>
<updated>2013-07-24T13:45:01+00:00</updated>
<author>
<name>Wolfgang Denk</name>
<email>wd@denx.de</email>
</author>
<published>2013-07-08T09:48:07+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=eee479cf6a4046d25f8032c402355d9fc237fb70'/>
<id>eee479cf6a4046d25f8032c402355d9fc237fb70</id>
<content type='text'>
Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>env: throw an error when an empty key is used</title>
<updated>2013-05-09T21:03:05+00:00</updated>
<author>
<name>Lucian Cojocar</name>
<email>cojocar@gmail.com</email>
</author>
<published>2013-04-28T11:31:57+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=e4fdcadd8a6eedb1edaabbc85c782b43d4e80fe2'/>
<id>e4fdcadd8a6eedb1edaabbc85c782b43d4e80fe2</id>
<content type='text'>
If the environment contains an entry like "=value" "\0" we should throw
an error when parsing the environment. Otherwise, U-Boot will enter in
an infinite loop.

Signed-off-by: Lucian Cojocar &lt;cojocar@gmail.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If the environment contains an entry like "=value" "\0" we should throw
an error when parsing the environment. Otherwise, U-Boot will enter in
an infinite loop.

Signed-off-by: Lucian Cojocar &lt;cojocar@gmail.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>"env grep" - add support for regular expression matches</title>
<updated>2013-05-01T20:24:00+00:00</updated>
<author>
<name>Wolfgang Denk</name>
<email>wd@denx.de</email>
</author>
<published>2013-03-23T23:50:32+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=be29df6a1ac286e6c482828db28ca96e187c7e00'/>
<id>be29df6a1ac286e6c482828db28ca96e187c7e00</id>
<content type='text'>
When CONFIG_REGEX is enabled, the new option "-e" becomes available
which causes regular expression matches to be used.  This allows for
example things like these:

- print all MAC addresses:

	=&gt; env grep -e eth.*addr
	eth1addr=00:10:ec:80:c5:15
	ethaddr=00:10:ec:00:c5:15

- print all variables that have at least 2 colons in their value:

	=&gt; env grep -v -e :.*:
	addip=setenv bootargs ${bootargs} ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}:${hostname}:${netdev}:off
	panic=1
	eth1addr=00:10:ec:80:c5:15
	ethaddr=00:10:ec:00:c5:15
	ver=U-Boot 2013.04-rc1-00289-g497746b-dirty (Mar 22 2013 - 12:50:25)

etc.

Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When CONFIG_REGEX is enabled, the new option "-e" becomes available
which causes regular expression matches to be used.  This allows for
example things like these:

- print all MAC addresses:

	=&gt; env grep -e eth.*addr
	eth1addr=00:10:ec:80:c5:15
	ethaddr=00:10:ec:00:c5:15

- print all variables that have at least 2 colons in their value:

	=&gt; env grep -v -e :.*:
	addip=setenv bootargs ${bootargs} ip=${ipaddr}:${serverip}:${gatewayip}:${netmask}:${hostname}:${netdev}:off
	panic=1
	eth1addr=00:10:ec:80:c5:15
	ethaddr=00:10:ec:00:c5:15
	ver=U-Boot 2013.04-rc1-00289-g497746b-dirty (Mar 22 2013 - 12:50:25)

etc.

Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>"env grep" - reimplement command using hexport_r()</title>
<updated>2013-05-01T20:24:00+00:00</updated>
<author>
<name>Wolfgang Denk</name>
<email>wd@denx.de</email>
</author>
<published>2013-03-23T23:50:29+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=5a31ea04c9ee5544fbb70ad7597ea4b294840eab'/>
<id>5a31ea04c9ee5544fbb70ad7597ea4b294840eab</id>
<content type='text'>
Also drop hstrstr_r() which is not needed any more.
The new code is way more flexible.

Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Also drop hstrstr_r() which is not needed any more.
The new code is way more flexible.

Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>hashtable: preparations to use hexport_r() for "env grep"</title>
<updated>2013-05-01T20:24:00+00:00</updated>
<author>
<name>Wolfgang Denk</name>
<email>wd@denx.de</email>
</author>
<published>2013-03-23T23:50:28+00:00</published>
<link rel='alternate' type='text/html' href='http://cgit.235523.xyz/u-boot.git/commit/?id=ea009d4743ab4b801703982086e053e74266ff4c'/>
<id>ea009d4743ab4b801703982086e053e74266ff4c</id>
<content type='text'>
The output of "env grep" is unsorted, and printing is done by a
private implementation to parse the hash table.  We have all the
needed code in place in hexport_r() alsready, so let's use this
instead.  Here we prepare the code for this, without any functional
changes yet.

Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The output of "env grep" is unsorted, and printing is done by a
private implementation to parse the hash table.  We have all the
needed code in place in hexport_r() alsready, so let's use this
instead.  Here we prepare the code for this, without any functional
changes yet.

Signed-off-by: Wolfgang Denk &lt;wd@denx.de&gt;
</pre>
</div>
</content>
</entry>
</feed>
