|
8 | 8 | *
|
9 | 9 | *
|
10 | 10 | * IDENTIFICATION
|
11 |
| - * $Header: /cvsroot/pgsql/src/interfaces/libpgtcl/Attic/pgtclCmds.c,v 1.74 2003/10/31 00:18:55 tgl Exp $ |
| 11 | + * $Header: /cvsroot/pgsql/src/interfaces/libpgtcl/Attic/pgtclCmds.c,v 1.75 2003/11/08 20:34:36 tgl Exp $ |
12 | 12 | *
|
13 | 13 | *-------------------------------------------------------------------------
|
14 | 14 | */
|
@@ -1218,7 +1218,11 @@ Pg_lo_read(ClientData cData, Tcl_Interp *interp, int objc,
|
1218 | 1218 |
|
1219 | 1219 | if (nbytes >=0)
|
1220 | 1220 | {
|
| 1221 | +#ifTCL_MAJOR_VERSION==8&&TCL_MINOR_VERSION >=1||TCL_MAJOR_VERSION>8 |
1221 | 1222 | bufObj=Tcl_NewByteArrayObj(buf,nbytes);
|
| 1223 | +#else |
| 1224 | +bufObj=Tcl_NewStringObj(buf,nbytes); |
| 1225 | +#endif |
1222 | 1226 |
|
1223 | 1227 | if (Tcl_ObjSetVar2(interp,bufVar,NULL,bufObj,
|
1224 | 1228 | TCL_LEAVE_ERR_MSG |TCL_PARSE_PART1)==NULL)
|
@@ -1313,7 +1317,11 @@ Pg_lo_write(ClientData cData, Tcl_Interp *interp, int objc,
|
1313 | 1317 | if (Tcl_GetIntFromObj(interp,objv[2],&fd)!=TCL_OK)
|
1314 | 1318 | returnTCL_ERROR;
|
1315 | 1319 |
|
| 1320 | +#ifTCL_MAJOR_VERSION==8&&TCL_MINOR_VERSION >=1||TCL_MAJOR_VERSION>8 |
1316 | 1321 | buf=Tcl_GetByteArrayFromObj(objv[3],&nbytes);
|
| 1322 | +#else |
| 1323 | +buf=Tcl_GetStringFromObj(objv[3],&nbytes); |
| 1324 | +#endif |
1317 | 1325 |
|
1318 | 1326 | if (Tcl_GetIntFromObj(interp,objv[4],&len)!=TCL_OK)
|
1319 | 1327 | returnTCL_ERROR;
|
|