summaryrefslogtreecommitdiffstats
path: root/generic/tclIORChan.c
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2017-04-11 15:20:07 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2017-04-11 15:20:07 (GMT)
commit4775249efa107caa7895328913957997cf0bc6d8 (patch)
treeca2f013549de2b7536af92162bcf4bade5d91f35 /generic/tclIORChan.c
parent90ca2f4448e5aba75ffe9b71d877b557264a90a0 (diff)
downloadtcl-4775249efa107caa7895328913957997cf0bc6d8.zip
tcl-4775249efa107caa7895328913957997cf0bc6d8.tar.gz
tcl-4775249efa107caa7895328913957997cf0bc6d8.tar.bz2
Remove some unnecessary "struct" definitions and some type casts no longer necessary. No functional changes.
Diffstat (limited to 'generic/tclIORChan.c')
-rw-r--r--generic/tclIORChan.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/generic/tclIORChan.c b/generic/tclIORChan.c
index 433fb6f..aefa104 100644
--- a/generic/tclIORChan.c
+++ b/generic/tclIORChan.c
@@ -234,7 +234,7 @@ typedef enum {
* sharing problems.
*/
-typedef struct ForwardParamBase {
+typedef struct {
int code; /* O: Ok/Fail of the cmd handler */
char *msgStr; /* O: Error message for handler failure */
int mustFree; /* O: True if msgStr is allocated, false if
@@ -309,7 +309,7 @@ typedef struct ForwardingResult ForwardingResult;
* General event structure, with reference to operation specific data.
*/
-typedef struct ForwardingEvent {
+typedef struct {
Tcl_Event event; /* Basic event data, has to be first item */
ForwardingResult *resultPtr;
ForwardedOperation op; /* Forwarded driver operation */
@@ -346,7 +346,7 @@ struct ForwardingResult {
* results. */
};
-typedef struct ThreadSpecificData {
+typedef struct {
/*
* Table of all reflected channels owned by this thread. This is the
* per-thread version of the per-interpreter map.
@@ -723,7 +723,7 @@ TclChanCreateObjCmd(
Tcl_DecrRefCount(rcPtr->name);
Tcl_DecrRefCount(rcPtr->methods);
Tcl_DecrRefCount(rcPtr->cmd);
- ckfree((char*) rcPtr);
+ ckfree(rcPtr);
return TCL_ERROR;
#undef MODE
@@ -748,7 +748,7 @@ TclChanCreateObjCmd(
*----------------------------------------------------------------------
*/
-typedef struct ReflectEvent {
+typedef struct {
Tcl_Event header;
ReflectedChannel *rcPtr;
int events;
@@ -1223,8 +1223,8 @@ ReflectClose(
#endif
tctPtr = ((Channel *)rcPtr->chan)->typePtr;
if (tctPtr && tctPtr != &tclRChannelType) {
- ckfree(tctPtr);
- ((Channel *)rcPtr->chan)->typePtr = NULL;
+ ckfree(tctPtr);
+ ((Channel *)rcPtr->chan)->typePtr = NULL;
}
Tcl_EventuallyFree(rcPtr, (Tcl_FreeProc *) FreeReflectedChannel);
return (result == TCL_OK) ? EOK : EINVAL;