This commit is contained in:
Mark Felder 2020-08-30 09:32:22 -05:00
parent 2d2af75777
commit 4ef210a587
2 changed files with 4 additions and 3 deletions

View file

@ -102,7 +102,7 @@ defp run_fifo(fifo_path, env, executable, args) do
File.rm(fifo_path)
end
defp mkfifo() do
defp mkfifo do
path = "#{@tmp_base}#{to_charlist(:erlang.phash2(self()))}"
case System.cmd("mkfifo", [path]) do

View file

@ -13,7 +13,7 @@ defmodule Pleroma.Helpers.QtFastStart do
# ISO/IEC 14496-12:2015, ISO/IEC 15444-12:2015
# Paracetamol
def fix(binary = <<0x00, 0x00, 0x00, _, 0x66, 0x74, 0x79, 0x70, _::bits>>) do
def fix(<<0x00, 0x00, 0x00, _, 0x66, 0x74, 0x79, 0x70, _::bits>> = binary) do
index = fix(binary, 0, nil, nil, [])
case index do
@ -59,7 +59,8 @@ defp fix(<<>>, _pos, _, _, acc) do
defp faststart(index) do
{{_ftyp, _, _, _, ftyp}, index} = List.keytake(index, "ftyp", 0)
# Skip re-writing the free fourcc as it's kind of useless. Why stream useless bytes when you can do without?
# Skip re-writing the free fourcc as it's kind of useless.
# Why stream useless bytes when you can do without?
{free_size, index} =
case List.keytake(index, "free", 0) do
{{_, _, _, size, _}, index} -> {size, index}