Linux and UNIX Man Pages

Linux & Unix Commands - Search Man Pages

siglongjmp(3) [ultrix man page]

sigsetjmp(3)						     Library Functions Manual						      sigsetjmp(3)

Name
       sigsetjmp, siglongjmp - nonlocal goto

Syntax
       #include <setjmp.h>

       sigsetjmp(env, savemask)
       sigjmp_buf env;

       void siglongjmp(env, val)
       sigjmp_buf env;

Description
       These routines deal with errors and interrupts encountered in a low-level subroutine of a program.

       The  subroutine	saves its stack environment in env for later use by It returns a value of 0.  If the value of the savemask argument is not
       zero, the subroutine also saves the process' current signal mask as part of the calling environment.

       The subroutine restores the environment saved by the last call of with the supplied env buffer.	If the env argument was initialized  by  a
       call to the subroutine with a nonzero savemask argument, the subroutine restores the saved signal mask.	It then returns in such a way that
       execution continues as if the call of had just returned the value val to the subroutine that invoked which must not itself have returned in
       the  interim.   However, cannot cause to return the value 0. If is invoked with a val of 0, returns a value of 1.  All accessible data have
       values as of the time was called.

Restrictions
       The subroutine does not save the current notion of whether the process is executing on the signal stack.  When you invoke  the  subroutine,
       the signal stack is left in an incorrect state.

See Also
       sigstack(2), sigvec(2), signal(3), sigprocmask(3)

																      sigsetjmp(3)

Check Out this Related Man Page

LONGJMP(3)							 Library functions							LONGJMP(3)

NAME
longjmp, siglongjmp - non-local jump to a saved stack context SYNOPSIS
#include <setjmp.h> void longjmp(jmp_buf env, int val); void siglongjmp(sigjmp_buf env, int val); DESCRIPTION
longjmp() and setjmp() are useful for dealing with errors and interrupts encountered in a low-level subroutine of a program. longjmp() restores the environment saved by the last call of setjmp() with the corresponding env argument. After longjmp() is completed, program execution continues as if the corresponding call of setjmp() had just returned the value val. longjmp() cannot cause 0 to be returned. If longjmp is invoked with a second argument of 0, 1 will be returned instead. siglongjmp() is similar to longjmp() except for the type of its env argument. If the sigsetjmp() call that set this env used a nonzero savesigs flag, siglongjmp() also restores the set of blocked signals. RETURN VALUE
These functions never return. CONFORMING TO
POSIX NOTES
POSIX does not specify whether longjmp will restore the signal context. If you want to save and restore signal masks, use siglongjmp. longjmp() and siglongjmp() make programs hard to understand and maintain. If possible an alternative should be used. SEE ALSO
setjmp(3), sigsetjmp(3) 1997-03-02 LONGJMP(3)
Man Page

15 More Discussions You Might Find Interesting

1. Programming

Signal Names

Hi everyone, Is there a variable or built in function in the Unix env. for me to obtain the name of a signal that is caught? As far as I understand only a numeric value of the signal is returned to the handler. For example: void handler (int signum) { ... (2 Replies)
Discussion started by: laila63
2 Replies

2. Programming

Clarification abt .profile,config,env

Hi, I need to know the purpose of .profile,config and env file . what is the 1)similarties 2)difference between these 3. If env is not a file, when we give command env we are getting some information, from where or which file we are getting this... (0 Replies)
Discussion started by: sarwan
0 Replies

3. UNIX for Advanced & Expert Users

How to edit env file

A coworker of mine wants to add some environment variables to env file. Please advise how to do it. He couldn't use: more or vi on the file. Thanks. (3 Replies)
Discussion started by: duke0001
3 Replies

4. Shell Programming and Scripting

shell script

if i do this 5 times env >> xx env >> xx env >> xx env >> xx env >> xx il will a file called XX with the env redirected into it 5 times i need to create a script that takes 1 argument being a file, in this instancei ll use the newly created file above xx read the inputted file, in this... (13 Replies)
Discussion started by: ciroredz
13 Replies

5. UNIX for Dummies Questions & Answers

displaying/ counting lines

I have a file called xx with the env redirected into it 5 times: env >> xx env >> xx env >> xx env >> xx env >> xx I have to read an input file (here: xx) and look for occurrences of the current user who is executing this script. Once finding an occurrence of the username I have to take that... (4 Replies)
Discussion started by: aga
4 Replies

6. Shell Programming and Scripting

displaying/ counting lines

I have a file called xx with the env redirected into it 5 times: env >> xx env >> xx env >> xx env >> xx env >> xx I have to read an input file (here: xx) and look for occurrences of the current user who is executing this script. Once finding an occurrence of the username I have to take that... (2 Replies)
Discussion started by: aga
2 Replies

7. UNIX Desktop Questions & Answers

Sftp Umask

Hi All, in my HP-UX 11.11 , there is an parameter of SFTP_UMASK at env, but How do we use it ? I tried with type : SFTP_UMASK=022 and when I type : env the SFTP_UMASK value has changed to 022 . but when I send a file with use SFTP from other pc/server . It still umask 077 (chmod... (4 Replies)
Discussion started by: mdjuarsa
4 Replies

8. UNIX for Advanced & Expert Users

Permission denied

Hi, I can not execute a .env file $ . /Data/oracle/d03/mydbora/8.0.6/MYDB.env -bash: /Data/oracle/d03/mydbora/8.0.6/MYDB.env: Permission denied Even if : -rwxrwxrwx 1 oracle dba 2903 Mar 5 2007 /Data/oracle/d03/mydbora/8.0.6/MYDB.env Please help. Many thanks. (1 Reply)
Discussion started by: big123456
1 Replies

9. Programming

Debug env for long time use

Hi, I'm pritty new to C, but a recent bug in a program i've been using has forced me to debug it. But I am unable to find a debugger that can act as a layer between the OS and the program to see whats going on.. The problem is that this piece of software makes a connection through localhost... (2 Replies)
Discussion started by: nephilimbe
2 Replies

10. Programming

HOME env

Do you know shell in Linux without HOME env. Best regards, Iliyan Varshilov (1 Reply)
Discussion started by: ilko_partizan
1 Replies

11. UNIX for Dummies Questions & Answers

signal() and sigsetjmp()

Hi, I am basically new to signals in UNIX. My question is, should the signal() command be called only once in the program? What will happen if it's called multiple times? I am trying to write an alarm program where the signal handler function changes in runtime. It just doesn't work if I... (2 Replies)
Discussion started by: bashdrew
2 Replies

12. Shell Programming and Scripting

Identify env file called

Hi, please help me.. in how to find out which env file is being called upon when an os user logs. when i su - oracle , i would like to know which env is called, because i see many env files under the home dir.. thanks, (2 Replies)
Discussion started by: jjoy
2 Replies

13. UNIX for Dummies Questions & Answers

Appending from a file to a script and vice versa

Hi, I am new to Unix and discovered this example problem online that I believe will help my learning: Run the command's below env >> xx env >> xx env >> xx env >> xx env >> xx You will now have a file called XX with the env redirected into it 5 times Create a script named... (2 Replies)
Discussion started by: Jimmy_c
2 Replies

14. Web Development

Deny from env=env-variable Does not work

(Above from Apache docs). On my system, using: SetEnvIf User-Agent Mozilla IsBad=1 Order allow,deny Allow from all Deny from env=IsBad ...I see that environment variable is set (using phpinfo()) but the page is still served. No errors in the Apache logs. (1 Reply)
Discussion started by: gnurob
1 Replies

15. Shell Programming and Scripting

Environment file in Perl

hi all, i am new to perl scripting environment. i want to view the .env file. where'z the location of .env/.profile file in perl env. Please suggest.. ---------- Post updated at 10:53 AM ---------- Previous update was at 10:51 AM ---------- here is the path variable value: bash-2.05$... (3 Replies)
Discussion started by: lovelysethii
3 Replies