summaryrefslogtreecommitdiffstats
path: root/carbon/tkMacOSXEmbed.c
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2011-03-12 17:45:37 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2011-03-12 17:45:37 (GMT)
commite0b895874d5fa39f6d4134b407e930b80ee3ecd7 (patch)
tree08a6b50f74f697e9ebc1f689f06d7318c0aa83a2 /carbon/tkMacOSXEmbed.c
parent77d7867fd5b20233f0fa9163bd8a44d2ac274b0e (diff)
downloadtk-e0b895874d5fa39f6d4134b407e930b80ee3ecd7.zip
tk-e0b895874d5fa39f6d4134b407e930b80ee3ecd7.tar.gz
tk-e0b895874d5fa39f6d4134b407e930b80ee3ecd7.tar.bz2
Remove casts from uses of ckalloc/ckfree/... now that Tcl declares them to be
using useful casts internally.
Diffstat (limited to 'carbon/tkMacOSXEmbed.c')
-rw-r--r--carbon/tkMacOSXEmbed.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/carbon/tkMacOSXEmbed.c b/carbon/tkMacOSXEmbed.c
index 9f80401..275f61d 100644
--- a/carbon/tkMacOSXEmbed.c
+++ b/carbon/tkMacOSXEmbed.c
@@ -92,8 +92,7 @@ Tk_MacOSXSetEmbedHandler(
Tk_MacOSXEmbedGetOffsetInParentProc *getOffsetProc)
{
if (tkMacOSXEmbedHandler == NULL) {
- tkMacOSXEmbedHandler = (TkMacOSXEmbedHandler *)
- ckalloc(sizeof(TkMacOSXEmbedHandler));
+ tkMacOSXEmbedHandler = ckalloc(sizeof(TkMacOSXEmbedHandler));
}
tkMacOSXEmbedHandler->registerWinProc = registerWinProc;
tkMacOSXEmbedHandler->getPortProc = getPortProc;
@@ -137,7 +136,7 @@ TkpMakeWindow(
* Allocate sub window
*/
- macWin = (MacDrawable *) ckalloc(sizeof(MacDrawable));
+ macWin = ckalloc(sizeof(MacDrawable));
if (macWin == NULL) {
winPtr->privatePtr = NULL;
return None;
@@ -263,7 +262,7 @@ TkpUseWindow(
* Make the embedded window.
*/
- macWin = (MacDrawable *) ckalloc(sizeof(MacDrawable));
+ macWin = ckalloc(sizeof(MacDrawable));
if (macWin == NULL) {
winPtr->privatePtr = NULL;
return TCL_ERROR;
@@ -319,7 +318,7 @@ TkpUseWindow(
" does not correspond to a valid Tk Window.", NULL);
return TCL_ERROR;
} else {
- containerPtr = (Container *) ckalloc(sizeof(Container));
+ containerPtr = ckalloc(sizeof(Container));
containerPtr->parentPtr = NULL;
containerPtr->embedded = (Window) macWin;
@@ -392,7 +391,7 @@ TkpMakeContainer(
*/
Tk_MakeWindowExist(tkwin);
- containerPtr = (Container *) ckalloc(sizeof(Container));
+ containerPtr = ckalloc(sizeof(Container));
containerPtr->parent = Tk_WindowId(tkwin);
containerPtr->parentPtr = winPtr;
containerPtr->embedded = None;
@@ -1117,7 +1116,7 @@ EmbedWindowDeleted(
} else {
prevPtr->nextPtr = containerPtr->nextPtr;
}
- ckfree((char *) containerPtr);
+ ckfree(containerPtr);
}
}