a1200   NEWS   APPS   DOCS   ABOUT
a1200
----
a1200
----
Autodocs
 Libraries:
 iffparse.library
  AllocIFF
  AllocLocalItem
  CloseClipboard
  CloseIFF
  CollectionChunk
  CollectionChunks
  CurrentChunk
  EntryHandler
  ExitHandler
  FindCollection
  FindLocalItem
  FindProp
  FindPropContext
  FreeIFF
  FreeLocalItem
  GoodID
  GoodType
  IDtoStr
  InitIFF
  InitIFFasClip
  InitIFFasDOS
  LocalItemData
  OpenClipboard
  OpenIFF
  ParentChunk
  ParseIFF
  PopChunk
  PropChunk
  PropChunks
  PushChunk
  ReadChunkBytes
  ReadChunkRecords
  SetLocalItemPurge
  StopChunk
  StopChunks
  StopOnExit
  StoreItemInContext
  StoreLocalItem
  WriteChunkBytes
  WriteChunkRecords
Include
GuruMeditation
Docs » Autodocs » iffparse.library » OpenClipboard

NAME

	OpenClipboard -- create a handle on a clipboard unit. (V36)

SYNOPSIS

	ch = OpenClipboard(unitNumber)
D0 D0
struct ClipboardHandle *OpenClipboard(LONG);

FUNCTION

	Opens the clipboard.device and opens a stream for the specified unit
(usually PRIMARY_CLIP). This handle structure will be used as the
clipboard stream for IFFHandles initialized as clipboard streams by
InitIFFasClip().

INPUTS

	unitNumber - clipboard unit number (usually PRIMARY_CLIP).

RESULT

	ch - pointer to ClipboardHandle structure or NULL if unsuccessful.

BUGS

	This function had several bugs prior to V39.
First bug was that if the clipboard.device couldn't open, two calls
to FreeSignal() were made with uninitialized values as parameters.
The result of this was a corrupt signal mask in the Task field.
Second bug was that OpenDevice() was called with an IO request that
didn't have a valid MsgPort pointer in it.
Third bug was that the two message ports allocated by the function
(ClipboardHandle->cbh_CBport and ClipboardHandle->cbh_SatisfyPort)
were not being initialized correctly and would cause a system crash
if a message ever got to either of them.

SEE ALSO

InitIFFasClip(), CloseClipboard(), <libraries/iffparse.h>

Comments

Name:
E-mail: Use this if you want a message if you get a response, will not be shown.
Comment:
Select correct short for:

The Silents

AFL
TSL
RSI
DC

Comments:

$VER: d0.se 1.14 Copyright © 2011-2021 Tobias Geijersson support at d0 dot se