mirror of
https://github.com/Dushistov/sdcv.git
synced 2026-01-08 19:34:29 +00:00
Compare commits
5 Commits
488ec68854
...
v0.5.5
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
49c8094b53 | ||
|
|
4346e65bd3 | ||
|
|
d144e0310c | ||
|
|
6e36e7730c | ||
|
|
abe5e9e72f |
5
.github/workflows/main.yml
vendored
5
.github/workflows/main.yml
vendored
@@ -20,12 +20,13 @@ jobs:
|
||||
fail-fast: true
|
||||
|
||||
matrix:
|
||||
os: [ubuntu-latest]
|
||||
os: [ubuntu-20.04, ubuntu-latest]
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
submodules: 'recursive'
|
||||
- uses: jwlawson/actions-setup-cmake@v1.4
|
||||
if: matrix.os != 'ubuntu-latest'
|
||||
with:
|
||||
cmake-version: '3.5.1'
|
||||
github-api-token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
@@ -95,7 +95,7 @@ set(CPACK_PACKAGE_VENDOR "Evgeniy Dushistov <dushistov@mail.ru>")
|
||||
set(CPACK_PACKAGE_DESCRIPTION_FILE "${CMAKE_CURRENT_SOURCE_DIR}/README.org")
|
||||
set(CPACK_PACKAGE_VERSION_MAJOR "0")
|
||||
set(CPACK_PACKAGE_VERSION_MINOR "5")
|
||||
set(CPACK_PACKAGE_VERSION_PATCH "4")
|
||||
set(CPACK_PACKAGE_VERSION_PATCH "5")
|
||||
|
||||
set(sdcv_VERSION
|
||||
"${CPACK_PACKAGE_VERSION_MAJOR}.${CPACK_PACKAGE_VERSION_MINOR}.${CPACK_PACKAGE_VERSION_PATCH}")
|
||||
|
||||
3
NEWS
3
NEWS
@@ -1,3 +1,6 @@
|
||||
Version 0.5.5
|
||||
- Avoid crashes when passing unknown dicts to the -u flag (by NiLuJe)
|
||||
- Use off_t for stuff mainly assigned to a stat.st_size value
|
||||
Version 0.5.4
|
||||
- Use binary search for synonyms
|
||||
- Various improvments in work with synonyms
|
||||
|
||||
18
src/sdcv.cpp
18
src/sdcv.cpp
@@ -186,10 +186,13 @@ try {
|
||||
}
|
||||
|
||||
// add bookname to list
|
||||
gchar **p = get_impl(use_dict_list);
|
||||
while (*p) {
|
||||
order_list.push_back(bookname_to_ifo.at(*p));
|
||||
++p;
|
||||
for (gchar **p = get_impl(use_dict_list); *p != nullptr; ++p) {
|
||||
auto it = bookname_to_ifo.find(*p);
|
||||
if (it != bookname_to_ifo.end()) {
|
||||
order_list.push_back(it->second);
|
||||
} else {
|
||||
fprintf(stderr, _("Unknown dictionary: %s\n"), *p);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
std::string ordering_cfg_file = std::string(g_get_user_config_dir()) + G_DIR_SEPARATOR_S "sdcv_ordering";
|
||||
@@ -201,7 +204,12 @@ try {
|
||||
if (ordering_file != nullptr) {
|
||||
std::string line;
|
||||
while (stdio_getline(ordering_file, line)) {
|
||||
order_list.push_back(bookname_to_ifo.at(line));
|
||||
auto it = bookname_to_ifo.find(line);
|
||||
if (it != bookname_to_ifo.end()) {
|
||||
order_list.push_back(it->second);
|
||||
} else {
|
||||
fprintf(stderr, _("Unknown dictionary: %s\n"), line.c_str());
|
||||
}
|
||||
}
|
||||
fclose(ordering_file);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user