* The problem
Orgmode under macOS cannot display local images correctly, but it can display internet images without problem.
I tried both emacs-mac and emacs-plus, they both have this image problem. But emacs under ArchLinux don’t have this problem.
[[file:xxx.png]] cannot be displayed even the file exists.
[[./xxx.png]] cannot be displayed even the file exists.
[[http://example.org/xxx.png]] can be displayed if the link exists.
Emacs can display any images with C-x C-f xxx.png. The problem happens only with orgmode.
* The reason
After bisecting org-mode source code I found out that this commit causes the problem:
https://code.orgmode.org/bzg/org-mode/commit/48da60f47a77f4b99b4160fa620f258896ff4da3
Reverting to previous commit fixes the problem.
I’m new to Emacs and don’t understand the code of this commit. I cannot do further investigation.
* Screenshot
File content:
[[./cacochan.png]]
[[https://github.com/hlissner/doom-emacs/raw/screenshots/cacochan.png]]