diff options
author | Matthias P. Braendli <matthias.braendli@mpb.li> | 2018-02-15 10:40:01 +0100 |
---|---|---|
committer | Matthias P. Braendli <matthias.braendli@mpb.li> | 2018-02-15 10:40:01 +0100 |
commit | f183429878b305b0e8766aa68a88b96f2d9c1fd0 (patch) | |
tree | 39816a01e34587372bd754eb72b233c7f85cd017 /src/etianalyse.cpp | |
parent | baf3f64d01136e3a1e272d9a0e93ced59a27354e (diff) | |
download | etisnoop-f183429878b305b0e8766aa68a88b96f2d9c1fd0.tar.gz etisnoop-f183429878b305b0e8766aa68a88b96f2d9c1fd0.tar.bz2 etisnoop-f183429878b305b0e8766aa68a88b96f2d9c1fd0.zip |
Fix EEP_B in YAML
Diffstat (limited to 'src/etianalyse.cpp')
-rw-r--r-- | src/etianalyse.cpp | 23 |
1 files changed, 12 insertions, 11 deletions
diff --git a/src/etianalyse.cpp b/src/etianalyse.cpp index f416c77..a1218c7 100644 --- a/src/etianalyse.cpp +++ b/src/etianalyse.cpp @@ -556,18 +556,19 @@ void ETI_Analyser::eti_analyse() fprintf(stat_fd, " subchannel:\n"); fprintf(stat_fd, " id: %d\n", subch.id); fprintf(stat_fd, " SAd: %d\n", subch.start_addr); + + using ensemble_database::subchannel_t; switch (subch.protection_type) { - case ensemble_database::subchannel_t::protection_type_t::EEP: - if (subch.protection_option == 0) { - fprintf(stat_fd, " protection: EEP %d-A\n", - subch.protection_level + 1); - } - else if (subch.protection_option == 0) { - fprintf(stat_fd, " protection: EEP %d-B\n", - subch.protection_level + 1); - } - else { - fprintf(stat_fd, " protection: unknown\n"); + case subchannel_t::protection_type_t::EEP: + switch (subch.protection_option) { + case subchannel_t::protection_eep_option_t::EEP_A: + fprintf(stat_fd, " protection: EEP %d-A\n", + subch.protection_level + 1); + case subchannel_t::protection_eep_option_t::EEP_B: + fprintf(stat_fd, " protection: EEP %d-B\n", + subch.protection_level + 1); + default: + fprintf(stat_fd, " protection: unknown\n"); } fprintf(stat_fd, " size: %d\n", subch.size); |