;       SCCSID = @(#)sswthawp.asm	6.1 90/11/18

;      SCCSID = @(#)sswthawp.asm	6.3 90/03/19
; ****************************************************************************
; *									     *
; *			  IBM/Microsoft Confidential			     *
; *									     *
; *		    Copyright (c) IBM Corporation  1987, 1990		     *
; *		    Copyright (c) Microsoft Corp.  1987, 1990		     *
; *			      All Rights Reserved			     *
; *									     *
; ****************************************************************************

	 page 60,132


;*********************** START OF SPECIFICATIONS ***********************/
;								       */
;  SOURCE FILE NAME: SSWTHAWP					       */
;								       */
;  SUBROUTINE NAME:   SSTHAWPIDS				       */
;								       */
;  DESCRIPTIVE NAME:  Screen Switcher's subroutine to thaw pids        */
;								       */
;								       */
;  FUNCTION:  Allows Screen Switcher to thaw pids which it froze due   */
;	      to time out on screen locks during a screen switch.      */
;								       */
;								       */
;  NOTES:  Executes on Level 3					       */
;								       */
;  ENTRY POINT: SSTHAWPIDS					       */
;    LINKAGE:	EXTRN SSTHAWPIDS: NEAR				       */
;		CALL SSTHAWPIDS 				       */
;								       */
;  INPUT: Segment and index registers are pointing at shared memory    */
;	  DS points to common data segment. DI points to the sgcb.     */
;								       */
;								       */
;								       */
;  EXIT-NORMAL: 						       */
;								       */
;  EXIT-ERROR:	None						       */
;								       */
;  EFFECTS:  All processes frozen due to lock time-out are thawed      */
;								       */
;  INTERNAL REFERENCES: 					       */
;    ROUTINES:							       */
;								       */
;  EXTERNAL REFERENCES: 					       */
;    ROUTINES: DosSystemService 				       */
;								       */
;	Change History: 					       */
;								       */
;	@TL6 - 03/01/90 - DCR 704 - Merge SMG/SSW instance data into   */
;			  OS2CHAR				       */
;								       */
;************************ END OF SPECIFICATIONS ************************/


.xlist
INCLUDE SSWINC.INC
.list

EXTRN	procid:word
EXTRN	subfunction:word
EXTRN	actionpacket:word
EXTRN	responsepacket:word
EXTRN	lockfrozen:word

.386p

CODE	SEGMENT WORD PUBLIC 'CODE' USE16                                ;@TL6
	ASSUME	CS:CODE, DS:NOTHING,SS:NOTHING,ES:NOTHING		;@TL6
	 PUBLIC  SSTHAWPIDS

SSTHAWPIDS	PROC	NEAR



	 mov	 ax, [di].sgprocessfrozen  ; Get pid# which was
	 mov	 procid,ax		; frozen and thaw
	 mov	 subfunction,1

	 push	 0			; Sesmg. Service cat.
	 push	 ds			; function (= 3 for
	 push	 offset actionpacket	; freeze/thaw)
	 push	 ds			; stack
	 push	 offset responsepacket
	 call	 DOSSYSTEMSERVICE	; Thaw

	 .IF <zero ax>							;@TL6
	    mov     [di].sgprocessfrozen,ax ; IF WE EVER CALL PROC2	;@TL6
					    ; IN SSWRESTR WE MUST COMMENT
					    ; THIS MOVE TO
					    ; [DI].SGPROCESSFROZEN OUT
	    mov     lockfrozen,ax					;@TL6
	 .ENDIF

	 ret
SSTHAWPIDS	ENDP
CODE	ENDS								;@TL6
	 END
