Questions tagged [interruption]
126 questions
3
votes
1 answer
Interruption handling with non-static member function
I am trying to do interruption handling with a member function from a class.
The code is
signal(SIGABRT, socketServer.signalHandler);
where the definition of signalHandler is
public:
void SocketServer::signalHandler(int sig)
{
…

bxshi
- 2,252
- 5
- 31
- 50
3
votes
3 answers
Interrupt the thread
protected void waitAndSweep(String symbol) {
try {
long sweepTime = symbolInfo.getSweepTime(symbol);
long timeSinceLastSweep = System.currentTimeMillis() - sweepTime;
long waitTime = timeSinceLastSweep >= getInterval() ? 0 :…

user5367186
- 67
- 6
3
votes
3 answers
how to stop a thread with thread interrupt method
I am trying to learn thread interrupt and how to make a thread terminate without calling stop.
public class Test implements Runnable{
static Thread threadTest=null;
public static void main(String args[]){
…

coder25
- 2,363
- 12
- 57
- 104
3
votes
1 answer
Stack of hardware interrupt top-half in Linux kernel?
I know Linux kernel take thread kernel stack as ISR stack before 2.6.32, after 2.6.32, kernel uses separated stack, if wrong, please correct me.
Would you tell me when the ISR stack is setup/crated, or destroy if there is. Or tell me the source file…

Qiu Yangfan
- 871
- 11
- 25
3
votes
1 answer
If possible, how can one stop a print to stdout from interrupting what's been typed?
I have a basic command-line chat client and server in Python, but this would be applicable to probably any language. I ran into a very obvious problem, and I'm not sure if there would be any way around it (aside from using a GUI! Which would quickly…

Andrew
- 2,438
- 1
- 19
- 19
2
votes
4 answers
OS development: How to avoid an infinite loop after an exception routine
For some months I've been working on a "home-made" operating system.
Currently, it boots and goes into 32-bit protected mode.
I've loaded the interrupt table, but haven't set up the pagination (yet).
Now while writing my exception routines I've…

Eti
- 247
- 2
- 11
2
votes
2 answers
How Do I Interrupt a Find Dialog in Delphi?
I have a standard Find Dialog:
My program can process some very large files, and finding text in such files may take 10 or 20 seconds or more. So after the "Find Next" button is pressed, I change the cursor to an hourglass. I change it back to the…

lkessler
- 19,819
- 36
- 132
- 203
2
votes
2 answers
Eclipse interruptions under Mac OS 10.7 Lion
I upgraded to Mac OS 10.7 Lion a while ago, and although Eclipse (Eclipse Java EE IDE for Web Developers, Version: Helios Service Release 2) works fine two things go very slow:
Creating a new project used to take a few seconds, now it takes about…

Polarpro
- 85
- 1
- 3
- 11
2
votes
2 answers
Interrupting a thread while it is running; what is the impact of the next interruption?
Let's assume thread t1 is running (i.e. not in a sleep, wait or join state). Another thread t2 interrupts t1. The Javadoc says t1's interrupted status will be set.
Let's assume t1 falls into sleep, wait or join status later. What happens?
i) Is…

Jérôme Verstrynge
- 57,710
- 92
- 283
- 453
2
votes
1 answer
How to keep my audio app active in background when interruptions occurs?
I'm trying to use AVAudioSession and AVAudioPlayer and audio background mode to keep my app active in background.
It works fine if no interruptions arrives.
But,
when I received audioPlayerBeginInterruption message I launch a backgroundTask and…

nico24
- 121
- 2
- 4
2
votes
2 answers
IOS Audio interruption
I am developing an audio streaming app with the old AudioStreamer from Matt and i am trying to make the interruption (when receive a call) by using :
- (void)MyAudioSessionInterruptionListener(void *inClientData, UInt32 inInterruptionState)
{
…

Ben
- 1,031
- 3
- 17
- 31
2
votes
0 answers
How can I get background music to restart after an interruption such as a call
Background music in my game works fine and plays behind other sounds that get activated. The back ground music is in Did Move to view and is a SKAudionode.
When a call is received the background music stops and does not restart even if the home…

Joe
- 23
- 5
2
votes
1 answer
idt_table undefined! warning when compiling kernel module
I'm trying to use gate_desc *idt_table in a kernel module. The set_trap_gate() function defined in desc.h uses this pointer. In desc.h is also a definition : extern gate_desc idt_table[].
I tried different things:
use idt_table in my module…

jerome
- 91
- 1
- 1
- 2
2
votes
4 answers
Does a thread need to be in a RUNNABLE state before it can be interrupted?
Is it necessary for a thread in java to be in ready state before it gets interrupted by interrupt method?
I tried to check this by typing the above given code below.
class MyThread extends Thread
{
public void run() {
try
{
…

Deep Roy
- 89
- 10
2
votes
1 answer
Java Thread.interrupted and interruption flag
I'm going through this tutorial on Java concurrency. There's a snippet provided in the linked article regarding the implementation of Thread.interrupted.
The interrupt mechanism is implemented using an internal flag known as the interrupt status.…

Carpetfizz
- 8,707
- 22
- 85
- 146