chiark
/
gitweb
/
~ian
/
chiark-tcl.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
wiringpi: drop piFace
[chiark-tcl.git]
/
hbytes
/
hook.c
diff --git
a/hbytes/hook.c
b/hbytes/hook.c
index b2d4dc4e1abc657da57497315d8999b1795a2363..f570709494ce0588c29de51ed97ca254287cb794 100644
(file)
--- a/
hbytes/hook.c
+++ b/
hbytes/hook.c
@@
-1,6
+1,6
@@
/*
* hbytes - hex-stringrep efficient byteblocks for Tcl
/*
* hbytes - hex-stringrep efficient byteblocks for Tcl
- * Copyright 2006 Ian Jackson
+ * Copyright 2006
-2012
Ian Jackson
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
@@
-13,9
+13,7
@@
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
- * along with this library; if not, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
- * 02110-1301, USA.
+ * along with this library; if not, see <http://www.gnu.org/licenses/>.
*/
*/
@@
-98,8
+96,8
@@
static void hbytes_t_ustr(Tcl_Obj *o) {
}
static int hbytes_t_sfa(Tcl_Interp *ip, Tcl_Obj *o) {
}
static int hbytes_t_sfa(Tcl_Interp *ip, Tcl_Obj *o) {
- char *str, *ep
, *os
;
- Byte *
startbytes, *
bytes;
+ char *str, *ep;
+ Byte *bytes;
int l;
char cbuf[3];
int l;
char cbuf[3];
@@
-111,13
+109,13
@@
static int hbytes_t_sfa(Tcl_Interp *ip, Tcl_Obj *o) {
} else {
} else {
-
os=
str= Tcl_GetStringFromObj(o,&l); assert(str);
+ str= Tcl_GetStringFromObj(o,&l); assert(str);
cht_objfreeir(o);
if (l & 1) return cht_staticerr(ip, "hbytes: conversion from hex:"
" odd length in hex", "HBYTES SYNTAX");
cht_objfreeir(o);
if (l & 1) return cht_staticerr(ip, "hbytes: conversion from hex:"
" odd length in hex", "HBYTES SYNTAX");
-
startbytes=
bytes= cht_hb_arrayspace(OBJ_HBYTES(o), l/2);
+ bytes= cht_hb_arrayspace(OBJ_HBYTES(o), l/2);
cbuf[2]= 0;
while (l>0) {
cbuf[2]= 0;
while (l>0) {