The LINE-ATT command attaches the specified line to the current process. When you attach a line to your process, your process has exclusive use of that line. No other process can use the line for input or output until you detach the line with the LINE-DET command. You must have SYS1 privileges to use LINE-ATT.
Format
LINE-ATT line [(U)] |
Parameter(s)
line |
Number of the line you want to attach. |
U |
Breaks the attachment of any other process to the specified line and attaches that line to your process. You must have SYS2 privileges to use the U option. |
Description
When the line is successfully attached, the following message displays:
[8013] LINE n ATTACHED. |
n |
Line you specified. If the line you specify is currently attached or linked to another process, the following message displays:
|
If the U option is used, any existing attachment to the specified line is broken, and the line is attached to your process. However, any existing links will not be broken. If the line is linked to another process, you must first use the UNLINK-LINE command, which both unlinks the line from its currently linked process and unattaches it if it is attached. You can then use LINE-ATT to attach the line to your process.
Attaching to a Line
The following example shows what happens when you try to attach to a line that is currently linked to another process. You must first unlink the line with UNLINK-LINE, then attach the line to your process with LINE-ATT. UNLINK-LINE is a SYSPROG command.
>LINE-ATT 2 [8011] LINE IN USE.
>UNLINK-LINE 2 [8012] LINE 2 UNLINKED.
>LINE-ATT 2 [8013] LINE 2 ATTACHED.
> |
Attaching to a Line That Is Already Attached to Another Process
The following example breaks any existing attachment to line 5 and attaches it to your process:
>LINE-ATT 5 (U) [8013] LINE 5 ATTACHED. |
If line 5 were linked to a process, it would not be unlinked. The U option works only on lines that are attached but not linked to another process.