comparison src/sighandlers.cc @ 14861:f7afecdd87ef

maint: Use Octave coding conventions for cuddling parentheses in src/ directory * bitfcns.cc, comment-list.cc, data.cc, defun.cc, error.cc, gl-render.cc, graphics.cc, graphics.in.h, load-path.cc, load-path.h, load-save.cc, ls-hdf5.cc, ls-mat4.cc, ls-mat5.cc, ls-oct-ascii.cc, mappers.cc, mex.cc, oct-map.cc, oct-obj.cc, ov-base-int.cc, ov-base-mat.h, ov-base-sparse.cc, ov-bool-mat.cc, ov-bool-sparse.cc, ov-cell.cc, ov-class.cc, ov-complex.cc, ov-cx-mat.cc, ov-cx-sparse.cc, ov-fcn-handle.cc, ov-flt-cx-mat.cc, ov-flt-re-mat.cc, ov-re-mat.cc, ov-re-sparse.cc, ov-scalar.cc, ov-str-mat.cc, ov-struct.cc, ov-usr-fcn.cc, ov.cc, pr-output.cc, procstream.h, sighandlers.cc, sparse-xdiv.cc, sparse-xpow.cc, sparse.cc, symtab.cc, syscalls.cc, sysdep.cc, txt-eng-ft.cc, variables.cc, zfstream.cc, zfstream.h: Use Octave coding conventions for cuddling parentheses.
author Rik <octave@nomad.inbox5.com>
date Sat, 14 Jul 2012 06:22:56 -0700
parents 47fba1dc31b8
children 577df411e0c7
comparison
equal deleted inserted replaced
14860:e027f98403c3 14861:f7afecdd87ef
250 { 250 {
251 octave_signal_caught = 1; 251 octave_signal_caught = 1;
252 252
253 octave_signals_caught[SIGCHLD] = true; 253 octave_signals_caught[SIGCHLD] = true;
254 } 254 }
255 #endif /* defined(SIGCHLD) */ 255 #endif /* defined (SIGCHLD) */
256 256
257 #ifdef SIGFPE 257 #ifdef SIGFPE
258 #if defined (__alpha__) 258 #if defined (__alpha__)
259 static void 259 static void
260 sigfpe_handler (int /* sig */) 260 sigfpe_handler (int /* sig */)
266 octave_signals_caught[SIGFPE] = true; 266 octave_signals_caught[SIGFPE] = true;
267 267
268 octave_interrupt_state++; 268 octave_interrupt_state++;
269 } 269 }
270 } 270 }
271 #endif /* defined(__alpha__) */ 271 #endif /* defined (__alpha__) */
272 #endif /* defined(SIGFPE) */ 272 #endif /* defined (SIGFPE) */
273 273
274 #if defined (SIGHUP) || defined (SIGTERM) 274 #if defined (SIGHUP) || defined (SIGTERM)
275 static void 275 static void
276 sig_hup_or_term_handler (int sig) 276 sig_hup_or_term_handler (int sig)
277 { 277 {
399 // Don't loop forever on account of this. 399 // Don't loop forever on account of this.
400 400
401 if (pipe_handler_error_count++ > 100 && octave_interrupt_state >= 0) 401 if (pipe_handler_error_count++ > 100 && octave_interrupt_state >= 0)
402 octave_interrupt_state++; 402 octave_interrupt_state++;
403 } 403 }
404 #endif /* defined(SIGPIPE) */ 404 #endif /* defined (SIGPIPE) */
405 405
406 #ifdef USE_W32_SIGINT 406 #ifdef USE_W32_SIGINT
407 static BOOL CALLBACK 407 static BOOL CALLBACK
408 w32_sigint_handler (DWORD sig) 408 w32_sigint_handler (DWORD sig)
409 { 409 {
410 const char *sig_name; 410 const char *sig_name;
411 411
412 switch(sig) 412 switch (sig)
413 { 413 {
414 case CTRL_BREAK_EVENT: 414 case CTRL_BREAK_EVENT:
415 sig_name = "Ctrl-Break"; 415 sig_name = "Ctrl-Break";
416 break; 416 break;
417 case CTRL_C_EVENT: 417 case CTRL_C_EVENT:
429 default: 429 default:
430 sig_name = "unknown console event"; 430 sig_name = "unknown console event";
431 break; 431 break;
432 } 432 }
433 433
434 switch(sig) 434 switch (sig)
435 { 435 {
436 case CTRL_BREAK_EVENT: 436 case CTRL_BREAK_EVENT:
437 case CTRL_C_EVENT: 437 case CTRL_C_EVENT:
438 w32_raise (SIGINT); 438 w32_raise (SIGINT);
439 break; 439 break;
445 case CTRL_SHUTDOWN_EVENT: 445 case CTRL_SHUTDOWN_EVENT:
446 default: 446 default:
447 // We should do the following: 447 // We should do the following:
448 // clean_up_and_exit (0); 448 // clean_up_and_exit (0);
449 // We can't because we aren't running in the normal Octave thread. 449 // We can't because we aren't running in the normal Octave thread.
450 user_abort(sig_name, sig); 450 user_abort (sig_name, sig);
451 break; 451 break;
452 } 452 }
453 453
454 // Return TRUE if the event was handled, or FALSE if another handler 454 // Return TRUE if the event was handled, or FALSE if another handler
455 // should be called. 455 // should be called.