summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)AuthorLines
2021-09-09feh_http_load_image: Use mkstemps to save image with correct suffixDaniel Friesel-4/+25
This allows feh to load .gif images via libcurl, as some imlib2 versions only load gif images if the suffix is correct. It's also more convenient when using --keep-http. To achieve this, feh needs to use mkstemps. mkstemps is a non-standard extension that is available on several systems. Compile feh with "mkstemps=0" to use mkstemp instead. Closes #630
2021-07-25Set correct window size when applying --zoom outside of -. / -FDaniel Friesel-3/+18
Needs further testing
2021-07-24Fix implicit definition of `strverscmp`.Olof-Joachim Frahm (欧雅福)-8/+4
2021-07-23Fix memory leak on error pathTobias Stoeckmann-1/+1
The snprintf string argument should not be duplicated. It is not needed and also not released afterwards.
2021-07-23Fix out of boundary access on illegal argumentTobias Stoeckmann-1/+1
Calling feh with an empty argument leads to out of boundary access. This can be seen best when compiled with asan: $ feh ""
2021-07-23feh_draw_exif: Fix out of bounds array access when handling long linesDaniel Friesel-4/+3
2021-07-23Fix out of boundary access with exif (#617)Tobias Stoeckmann-15/+15
* Fix out of boundary access The while-loop is not finished when pos is set to EXIF_MAX_DATA. Instead, the loop continues and therefore tries to access data outside of the array. This is triggered when compiled with exif=1 and asan: $ feh --draw-exif image.jpg * Fixed formatting No functional change but makes previous commit easier verifiable (independent of tab space setup). * Call break; instead of setting pos2 to a magic value This is in line with the following else clause * Another cosmetic adjustment Co-authored-by: Daniel Friesel <derf@finalrewind.org>
2021-06-21Fix feh_is_image for tiny filesDavid Buchanan-1/+3
2021-06-09Add JPEG XL to supported file formatsAlistair-0/+5
Note that Imlib2 does not support JXL images out of the box. However, the imlib2-jxl loader (https://github.com/alistair7/imlib2-jxl) does.
2021-05-09Release v3.73.7Daniel Friesel-1/+1
2021-05-09Merge branch 'simplify-exif'Daniel Friesel-98/+179
2021-05-08rename --zoom-rate to --zoom-step and switch to percentDaniel Friesel-7/+7
This is consistent with --scroll-step (option name) and --zoom (percentage)
2021-05-08getopt.c: Add missing string.h include (#530)Daniel Friesel-0/+1
2021-04-10EXIF: Use rawtherapee / flickr style output instead of "key: value" listsimplify-exifDaniel Friesel-98/+179
2021-04-10src/exif*: follow feh indentationDaniel Friesel-685/+729
2021-03-10Add support for gopher and gophers in utils/path_is_url.parazyd-0/+2
Both of these protocols are supported in latest curl. Signed-off-by: parazyd <parazyd@dyne.org>
2021-03-06help.raw: Add --window-id argumentDaniel Friesel-1/+1
2021-03-05Set original_file_items when using --start-at without file argumentsDaniel Friesel-0/+1
This makes --(auto-)reload use the directory specified at --start-at instead of the current working directory. Closes #597
2021-03-03Option Refactor and addition of Zoom Rate (#589)Alec C-203/+325
* fixed for simpler parenthesis matching * absolute file path for .fehbg, moved script creation into helper function * Removed unused variable. * added early exit condition as per Ferada's suggestion * Added enum for options to improve readability * migrated options to enum. * added support for zoom specification through options * added man entry for zoom-rate * added help entry for zoom-rate commands * updated man to have warnings about strange values for zoom options * fix memory leak (free exec_absolute_path) * added detection for path vs env PATH launch for use in .fehbg script gen. * Added enum for options to improve readability * migrated options to enum. * added support for zoom specification through options * added man entry for zoom-rate * added help entry for zoom-rate commands * updated man to have warnings about strange values for zoom options * Update help.raw removed zoom-in/out * removed zoom-in/out from options * updated man/help entry to remove in/out zoom specification * sanitize --zoom-rate in options parser; use a single variable for storing it Co-authored-by: Daniel Friesel <derf@finalrewind.org>
2021-03-01stdin keyboard input: Ignore uninitialized keysymsDaniel Friesel-1/+1
This fixes Ctrl+key causing unintended behaviour. Closes #596
2021-02-28Merge pull request #531 from Ferada/fix-some-warningsDaniel Friesel-8/+14
Fix some warnings from `gcc`.
2021-02-27feh_event_handle_stdin: handle EOFDaniel Friesel-1/+1
Closes #595
2021-01-28Merge pull request #588 from avlec/masterDaniel Friesel-83/+102
.fehbg now stores the full path to the feh binary when it was run using a relative path (i.e., not from $PATH)
2021-01-28added detection for path vs env PATH launch for use in .fehbg script gen.Alec Cox-4/+12
2021-01-28fix memory leak (free exec_absolute_path)Daniel Friesel-0/+1
2021-01-26added early exit condition as per Ferada's suggestionAlec Cox-72/+73
2021-01-25Removed unused variable.Alec Cox-2/+0
2021-01-25absolute file path for .fehbg, moved script creation into helper functionAlec Cox-82/+92
2021-01-24Handle URL-encoded components in "feh --start-at file://...."Daniel Friesel-3/+47
Closes #584
2021-01-24free opt.start_list_at before NULLing itDaniel Friesel-0/+3
2021-01-23wallpaper.h: Remove useless _XFUNCPROTO wrappersDaniel Friesel-2/+1
feh is C code, _XFUNCPROTO(BEGIN|END) are only needed for C++ applications.
2021-01-22fixed for simpler parenthesis matchingAlec Cox-2/+3
2021-01-09Rename --windowid to --window-id; add usage warning to documentationDaniel Friesel-2/+2
2021-01-09X11 uses unsigned long int for window IDs (see X11/X.h)Daniel Friesel-2/+2
2021-01-09Merge branch 'add-windowid-option' of https://github.com/codehearts/feh into ↵Daniel Friesel-5/+32
codehearts-add-windowid-option
2021-01-09distinguish between "missing magic bytes" and "no Imlib 2 loader" errorsDaniel Friesel-27/+59
2021-01-04Fix truncated image file descriptor leakEkho-0/+1
Fixes https://github.com/derf/feh/issues/580
2021-01-03Add heic/heif to supported file formatsDaniel Friesel-0/+5
Note that Imlib2 does not support HEIC/HEIF images out of the box. However, the imlib2-heic loader (https://github.com/vi/imlib2-heic) does. Closes #579
2020-12-24save_filelist: Respect --output-dirDaniel Friesel-1/+10
Closes #577
2020-12-05fix memory leak when (re)loading HTTP files with --no-conversion-cacheDaniel Friesel-1/+1
2020-12-05fix memory leak when using exif=1 and reloading an imageDaniel Friesel-6/+15
2020-12-05Fix memory leak in feh_draw_exifDaniel Friesel-0/+1
2020-12-05free accompanying EXIF data when freeing an imageDaniel Friesel-1/+21
This fixes two memory bugs that only manifest with exif=1 and long-running slideshows. * when feh loads an image, it writes exif data to file->ed. Previously, this data was never free'd, causing a memory leak on subsequent loads of the same file. * As file->ed is never free'd, the accumulated EXIF data consumes a significant amount of memory over time. with slideshow-delay = 10 and two days of runtime, feh may exceed 1 GB of memory usage. If the slideshow is so large that feh does not encounter the same image twice in this time, this is not detected as a memory leak, as each EXIF data chunk is referenced from the filelist. See <https://github.com/derf/feh/issues/553> for details. Closes #553
2020-11-30menu: Set flip/rotate menu title based on --editDaniel Friesel-1/+6
If --edit is set, it is indeed "Edit in Place". Otherwise, it changes the view, but not the image on the disk.
2020-11-30Merge branch 'menu' of https://github.com/Eelis/feh into Eelis-menuDaniel Friesel-0/+10
2020-11-30Check magic bytes before passing a file to Imlib2's loaderDaniel Friesel-3/+100
This works around a regression in Imlib2, which makes (un)loadable file detection quite slow when handling e.g. large video files. See <https://phab.enlightenment.org/T8739> and <https://github.com/derf/feh/issues/505> for details. Closes #505
2020-11-14Add menu entries for mirror and flip operationsEelis van der Weegen-0/+10
2020-08-28Fix segfault when closing a window in multi-window reload modeDaniel Friesel-2/+37
Issue: * start feh --multiwindow --reload 5 * close a window with "x" * wait up to 5 seconds * segfault The issue was caused by the closed window's reload timer still being active even after the winwidget was free'd.
2020-08-28Fix segmentation fault when combining --multiwindow and --reloadDaniel Friesel-36/+43
Introduced in 3fa39154f089a6fadc1a14eb6b206e2d2875be71
2020-07-24Add windowid option to draw to an existing windowKate Hart-5/+32
This lets `feh` draw the background pixmap of an existing window, opening the door for use with tools like `xscreensaver` or `xsecurelock`