Throws exception on waiting for an invalid tag

This commit is contained in:
Tristan B. Kildaire 2020-06-23 14:52:43 +02:00
parent 8f19f2ec7f
commit c1af63ba89
3 changed files with 13 additions and 4 deletions

View File

@ -2,6 +2,6 @@
"fileVersion": 1,
"versions": {
"bformat": "1.0.8",
"tristanable": "0.0.19"
"tristanable": "0.0.21"
}
}

View File

@ -2,6 +2,6 @@
"fileVersion": 1,
"versions": {
"bformat": "1.0.8",
"tristanable": "0.0.19"
"tristanable": "0.0.21"
}
}

View File

@ -141,10 +141,11 @@ public final class Manager
/* Throw an exception if it doesn't exist */
if(!isValidTag(tag))
{
/* TODO: Throw exception here */
/* Unlock the queue */
unlockQueue();
/* Throw exception here */
throw new TristanFokop("Invalid tag");
}
/* Get the request */
@ -187,4 +188,12 @@ public final class Manager
{
queueMutex.unlock();
}
}
public final class TristanFokop : Exception
{
this(string message)
{
super(message);
}
}