| summaryrefslogtreecommitdiff |
diff options
| author | Nathanael Sensfelder <SpamShield0@MultiAgentSystems.org> | 2017-02-13 18:02:32 +0100 |
|---|---|---|
| committer | Nathanael Sensfelder <SpamShield0@MultiAgentSystems.org> | 2017-02-13 18:02:32 +0100 |
| commit | f25fa7b132ef08431455075dadcf1823a5796dba (patch) | |
| tree | 2ee12d2745eff192d23f1dd29de43ab83ed0c26a /src/sequence | |
| parent | 7af295b2ec22f06b24079bf895ac97079f64b6d7 (diff) | |
Seems to work reasonably well.code-improvements
Diffstat (limited to 'src/sequence')
| -rw-r--r-- | src/sequence/sequence_append.c | 4 | ||||
| -rw-r--r-- | src/sequence/sequence_creation.c | 19 | ||||
| -rw-r--r-- | src/sequence/sequence_to_string.c | 8 |
3 files changed, 21 insertions, 10 deletions
diff --git a/src/sequence/sequence_append.c b/src/sequence/sequence_append.c index 81dfa99..d69db51 100644 --- a/src/sequence/sequence_append.c +++ b/src/sequence/sequence_append.c @@ -75,8 +75,8 @@ static int increment_required_capacity ZoO_S_ERROR ( io, - "Sequence capacity increment aborted, as the new size would not fit" - " in a size_t variable." + "Sequence capacity increment aborted, as the new size would not fit " + "in a size_t variable." ); #endif diff --git a/src/sequence/sequence_creation.c b/src/sequence/sequence_creation.c index 9556693..06c391f 100644 --- a/src/sequence/sequence_creation.c +++ b/src/sequence/sequence_creation.c @@ -260,7 +260,13 @@ static int extend_right { (void) ZoO_knowledge_unlock_access(k, io); - /* TODO: Err message. */ + ZoO_S_PROG_ERROR + ( + io, + "Knowledge consistency error: generated markov sequence could not be " + "found." + ); + return -1; } @@ -281,7 +287,12 @@ static int extend_right { (void) ZoO_knowledge_unlock_access(k, io); - /* TODO: Err message. */ + ZoO_S_PROG_ERROR + ( + io, + "Knowledge consistency error: generated markov sequence had no known " + "targets." + ); return -1; } @@ -468,6 +479,8 @@ static int initialize_sequence return -1; } + (void) ZoO_knowledge_unlock_access(k, io); + if (ZoO_DEBUG_SEQUENCE_CREATION_INIT) { ZoO_index i; @@ -485,8 +498,6 @@ static int initialize_sequence } } - (void) ZoO_knowledge_unlock_access(k, io); - return 0; } diff --git a/src/sequence/sequence_to_string.c b/src/sequence/sequence_to_string.c index 919ef0b..8666204 100644 --- a/src/sequence/sequence_to_string.c +++ b/src/sequence/sequence_to_string.c @@ -69,8 +69,8 @@ static int increment_required_capacity ZoO_S_ERROR ( io, - "String capacity increment aborted, as the new capacity would not" - " fit in a ZoO_index variable." + "String capacity increment aborted, as the new capacity would not " + "fit in a ZoO_index variable." ); return -1; @@ -85,8 +85,8 @@ static int increment_required_capacity ZoO_S_ERROR ( io, - "String capacity increment aborted, as the new size would not fit" - " in a size_t variable." + "String capacity increment aborted, as the new size would not fit " + "in a size_t variable." ); return -2; |


