about summary refs log tree commit diff stats
path: root/src/omemo
diff options
context:
space:
mode:
authorMichael Vetter <jubalh@iodoru.org>2023-04-14 13:14:01 +0200
committerGitHub <noreply@github.com>2023-04-14 13:14:01 +0200
commita99a4fad3ecb1d7641f4b8f971838c7be1c16074 (patch)
tree19afcfd1024e8251563bd86ca3dad986daa1bcca /src/omemo
parentebec68821fa816ca181892919bd878e69d35810d (diff)
parent899b26b3bce7bc7575be79df0cb9462c9e17623a (diff)
downloadprofani-tty-a99a4fad3ecb1d7641f4b8f971838c7be1c16074.tar.gz
Merge pull request #1823 from H3rnand3zzz/fix/msg-crash
Fix memory corruption crash
Diffstat (limited to 'src/omemo')
0 files changed, 0 insertions, 0 deletions
>
da925d06 ^

a621ef95 ^



da925d06 ^
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20




                                                                     

             

                                                                                             
   
                                                       
                  
                                   

        



                                                                    
 
# example program: copy one file into another, character by character
# BEWARE: this will modify your file system
# before running it, put some text into /tmp/mu-x
# after running it, check /tmp/mu-y

def main [
  local-scope
  source-file:&:source:char <- start-reading null/real-filesystem, [/tmp/mu-x]
  sink-file:&:sink:char, write-routine:num <- start-writing null/real-filesystem, [/tmp/mu-y]
  {
    c:char, done?:bool, source-file <- read source-file
    break-if done?
    sink-file <- write sink-file, c
    loop
  }
  close sink-file
  # make sure to wait for the file to be actually written to disk
  # (Mu practices structured concurrency: http://250bpm.com/blog:71)
  wait-for-routine write-routine
]