Thilo Graf
2570333010
helpers.h/cpp: add default timeout parameter with value 1
...
For flexible usage of timeout in related downloadUrl methods if required.
2020-11-16 08:37:53 +01:00
TangoCash
878b3bc03b
set download logo timeout to 1 sec
2020-11-16 08:02:34 +01:00
svenhoefer
31cea8ca29
- helpers: add function to get backup suffix
...
Signed-off-by: Thilo Graf <dbt@novatux.de >
2020-11-15 15:31:43 +01:00
TangoCash
031f8eb12c
keep all logo-naming conventions together
2020-09-24 17:12:10 +02:00
Markus Volk
7c5f7573e6
helpers.cpp: fix narrowing conversion
...
switch expression is 'int', but f_type gets stored as 'long unsigned int' on 32-bit machines since it may not fit otherwise. Recent compilers diagnose this and bail out with:
../../../git/src/system/helpers.cpp:330:9: error: narrowing conversion of '2240043254' from 'long unsigned int' to 'int' [-Wnarrowing]
casting the switch expression to long unsigned int seems to be the solution.
in short: this fixes the build for 32-bit machines with gcc ≥ 10.x
Signed-off-by: Markus Volk <f_l_k@t-online.de >
2020-08-05 05:33:57 +02:00
Thilo Graf
75d77244f8
helpers.cpp: add add script name to debug output
2020-07-07 20:02:51 +02:00
svenhoefer
df692287d8
- rework VUPLUS defines
...
Conflicts:
src/gui/cam_menu.cpp
src/neutrino_menue.cpp
src/zapit/src/zapit.cpp
Signed-off-by: Thilo Graf <dbt@novatux.de >
2020-06-15 20:00:35 +02:00
Thilo Graf
f71e5a1e5f
add boxmodel OSMIO4K
...
update to version 3.11.1
2020-02-19 21:42:18 +01:00
Markus Volk
bc0165ae75
unify boxmodel name
2020-02-18 18:48:30 +01:00
Markus Volk
6aa82141ff
add osmioplus4k stb
2020-02-16 08:42:17 +01:00
svenhoefer
cff41d02e4
- helpers: fix getBaseName() and getFileExt() for urls with query-strings
...
Signed-off-by: Thilo Graf <dbt@novatux.de >
2020-02-15 21:42:38 +01:00
svenhoefer
7c88a340df
- update: move function to get active partition to helpers.cpp
...
Signed-off-by: Thilo Graf <dbt@novatux.de >
2020-01-05 16:53:14 +01:00
GetAway
672959e68f
helpers.cpp: introduce safe_strncpy() and use it
2019-06-18 19:37:11 +02:00
Jacek Jendrzej
5fa551dab6
YT use htmlEntityDecode with title
2019-06-01 16:31:27 +02:00
Thilo Graf
5fa79b2232
helpers: add to_string() for char
2019-05-05 14:14:34 +02:00
Thilo Graf
cca09c7469
helpers: add trim methodes for left and right trim
2019-03-28 11:29:44 +01:00
Thilo Graf
531227a482
helpers: add isDigitWord() function
...
returns true if all chars of string parameter are digits
2019-03-28 11:29:41 +01:00
svenhoefer
b027bec157
- helpers: add function to execute control scripts
...
Signed-off-by: Thilo Graf <dbt@novatux.de >
2019-02-11 10:26:19 +01:00
Thilo Graf
ffbb24609c
helpers.cpp: reduce debug output in downloadUrl()
...
Usage of debug level INFO should be enough.
2018-10-28 19:41:22 +01:00
TangoCash
42e7b0a55f
adding caching xmltv logos
...
Signed-off-by: Thilo Graf <dbt@novatux.de >
2018-10-02 23:24:53 +02:00
svenhoefer
f5754b74f2
- helpers: rework new random-functions to get the code more reuseable
...
* introduceand use LOGODIR_TMP (storage dir for webchannel logos)
Signed-off-by: Thilo Graf <dbt@novatux.de >
2018-10-02 23:24:52 +02:00
TangoCash
1948302c72
adding download helping function
...
Signed-off-by: Thilo Graf <dbt@novatux.de >
2018-09-09 20:25:57 +02:00
TangoCash
cf885b1027
implement own tmp function / satify compiler
...
Signed-off-by: Thilo Graf <dbt@novatux.de >
2018-09-02 17:21:58 +02:00
Thilo Graf
bd36134e17
src/system/helpers.cpp: fix cherry pick
...
protected space was broken
2018-08-28 10:13:22 +02:00
TangoCash
153cce9d95
adding some curl helpers
...
Signed-off-by: Thilo Graf <dbt@novatux.de >
NOTE: this pick makes build broken because of some previous declarations
2018-08-23 10:37:56 +02:00
TangoCash
f8b623178e
fix webif xml encoding, part 2
2018-03-31 13:07:36 +02:00
Jacek Jendrzej
7ad4a0e6cc
Merge branch 'master' into pu/mp
2017-10-02 13:56:25 +02:00
Stefan Seyfried
2f39081708
helpers/readFile: limit memory allocations
2017-10-02 13:43:57 +02:00
M. Liebmann
600d215aaf
Merge branch 'master' into pu/mp
2017-09-19 23:21:21 +02:00
M. Liebmann
05d8ed4105
helpers.cpp: Add new functions
...
- readFile()
- parseJsonFromFile()
- parseJsonFromString()
parseJsonFromString() and parseJsonFromFile() use Json::CharReader
instead of the obsolete function Json::Reader
2017-09-19 23:20:39 +02:00
M. Liebmann
bdfccc2f22
Merge branch 'master' into pu/mp
2017-09-14 15:37:58 +02:00
M. Liebmann
020936acbe
system/helpers.cpp: Add cstr_replace()
...
- This is a faster C version of str_replace()
2017-09-14 15:37:36 +02:00
Jacek Jendrzej
2ebb47f519
Merge branch 'master' into pu/mp
2017-09-14 13:54:04 +02:00
svenhoefer
43c7e0ed09
helpers.chh/h: add some helper functions
...
Partial cherry pick from:
https://bitbucket.org/neutrino-images/ni-neutrino-hd
Signed-off-by: Thilo Graf <dbt@novatux.de >
2017-09-14 12:14:41 +02:00
Stefan Seyfried
5c95139207
Merge remote-tracking branch 'tuxbox/master'
2017-02-22 08:44:53 +01:00
M. Liebmann
0c182785e2
src/system/helpers.cpp: Add function readLink()
2017-02-22 06:24:48 +01:00
Stefan Seyfried
e1e2052edb
system/helpers: disable GetWidth4FB_HW_ACC()
...
...will be removed later
2017-02-14 20:01:55 +01:00
Stefan Seyfried
c95601630a
system/helpers: disable GetWidth4FB_HW_ACC()
...
...will be removed later
2017-02-14 00:15:11 +01:00
Stefan Seyfried
e490f84ea8
replace framebuffer.h include with forward declaration
...
instead of including framebuffer.h almost everywhere, replace it with
class CFrameBuffer forward declarations and/or generic system includes.
Add a hack to define fb_pixel_t to config.h (one reason for
framebuffer.h includes was the fb_pixel_t define)
2017-02-07 17:23:42 +01:00
Stefan Seyfried
63b6efd1f5
replace framebuffer.h include with forward declaration
...
instead of including framebuffer.h almost everywhere, replace it with
class CFrameBuffer forward declarations and/or generic system includes.
Add a hack to define fb_pixel_t to config.h (one reason for
framebuffer.h includes was the fb_pixel_t define)
2017-02-05 13:05:07 +01:00
Stefan Seyfried
85bb568d02
helpers: add run_pty() function
...
This runs an external command inside a pty. Running inside a pty,
external commands using stdio(3) will disable stdout buffering when
running from a terminal, which is often desirable.
2017-01-29 21:27:45 +01:00
Stefan Seyfried
9d78d7072d
helpers: add run_pty() function
...
This runs an external command inside a pty. Running inside a pty,
external commands using stdio(3) will disable stdout buffering when
running from a terminal, which is often desirable.
2017-01-28 23:17:03 +01:00
Stefan Seyfried
2c92d112d0
Merge remote-tracking branch 'tuxbox/master'
2016-11-12 18:06:26 +01:00
Jacek Jendrzej
80f7d0a299
helpers: 201103L have to_string
2016-10-24 13:41:23 +02:00
Stefan Seyfried
ae345d11d3
system/helpers: allow to build with c++11 compilers
2016-10-24 09:55:32 +02:00
Stefan Seyfried
645da64839
helpers.cpp: include fontrenderer.h
...
if Font class is used, the header should be included, too :-)
2016-10-24 09:46:05 +02:00
Stefan Seyfried
3684680cb2
system/helpers: allow to build with c++11 compilers
2016-10-22 12:23:09 +02:00
Stefan Seyfried
1d5cb34616
helpers.cpp: include fontrenderer.h
...
if Font class is used, the header should be included, too :-)
2016-10-22 12:22:06 +02:00
Stefan Seyfried
13ab1ebc8a
Merge remote-tracking branch 'tuxbox/master'
...
* needs compile fixes
* needs additional tests, of course :-)
2016-10-22 11:37:40 +02:00
M. Liebmann
6a9c08ae90
CFileHelpers: Rework FileBuf handling
...
FileBuf: Reserve memory only when it is needed (copyFile)
copyFile: Reserve for small files, only as much memory as is required
2016-09-06 11:32:41 +02:00