Rocksolid Light

Welcome to Rocksolid Light

mail  files  register  newsreader  groups  login

Message-ID:  

Memory fault -- brain fried


devel / comp.os.ms-windows.programmer.win32 / cdecl to stdcall

SubjectAuthor
* cdecl to stdcallmuta...@gmail.com
`* cdecl to stdcallmuta...@gmail.com
 `- cdecl to stdcallmuta...@gmail.com

1
cdecl to stdcall

<e665091a-17f8-42a5-af3c-e89d8ab33f75n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=530&group=comp.os.ms-windows.programmer.win32#530

  copy link   Newsgroups: comp.os.ms-windows.programmer.win32
X-Received: by 2002:ad4:5510:0:b0:61b:5faf:5f10 with SMTP id pz16-20020ad45510000000b0061b5faf5f10mr4392251qvb.5.1683897892910;
Fri, 12 May 2023 06:24:52 -0700 (PDT)
X-Received: by 2002:a05:622a:189b:b0:3f4:ed3e:7409 with SMTP id
v27-20020a05622a189b00b003f4ed3e7409mr1195326qtc.4.1683897892711; Fri, 12 May
2023 06:24:52 -0700 (PDT)
Path: i2pn2.org!rocksolid2!i2pn.org!weretis.net!feeder8.news.weretis.net!newsreader4.netcologne.de!news.netcologne.de!peer01.ams1!peer.ams1.xlned.com!news.xlned.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.os.ms-windows.programmer.win32
Date: Fri, 12 May 2023 06:24:52 -0700 (PDT)
Injection-Info: google-groups.googlegroups.com; posting-host=1.37.88.226; posting-account=CeHKkQoAAAAowY1GfiJYG55VVc0s1zaG
NNTP-Posting-Host: 1.37.88.226
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <e665091a-17f8-42a5-af3c-e89d8ab33f75n@googlegroups.com>
Subject: cdecl to stdcall
From: mutazilah@gmail.com (muta...@gmail.com)
Injection-Date: Fri, 12 May 2023 13:24:52 +0000
Content-Type: text/plain; charset="UTF-8"
X-Received-Bytes: 1594
 by: muta...@gmail.com - Fri, 12 May 2023 13:24 UTC

I would like to create a library that allows people with
compilers that only do cdecl (ie subc) to call Windows
functions.

So I created some assembler "glue".

I can get a link, but it doesn't actually create the directory,
and then it crashes.

I have tried various combinations.

Any ideas?

..386p
..model flat

..code

extrn __imp__CreateDirectoryA@8:dword
public _CreateDirectoryA
_CreateDirectoryA:
push 8[esp]
push 8[esp]
push [__imp__CreateDirectoryA@8]
ret
ret

Thanks. Paul.

Re: cdecl to stdcall

<093a5017-58ad-4c38-ae01-7fb973608e4bn@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=531&group=comp.os.ms-windows.programmer.win32#531

  copy link   Newsgroups: comp.os.ms-windows.programmer.win32
X-Received: by 2002:ac8:5744:0:b0:3f3:64fd:c684 with SMTP id 4-20020ac85744000000b003f364fdc684mr9031155qtx.5.1683898864459;
Fri, 12 May 2023 06:41:04 -0700 (PDT)
X-Received: by 2002:a05:620a:2985:b0:74a:8fd6:66de with SMTP id
r5-20020a05620a298500b0074a8fd666demr8604538qkp.6.1683898864222; Fri, 12 May
2023 06:41:04 -0700 (PDT)
Path: i2pn2.org!i2pn.org!weretis.net!feeder8.news.weretis.net!newsreader4.netcologne.de!news.netcologne.de!peer01.ams1!peer.ams1.xlned.com!news.xlned.com!peer03.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.os.ms-windows.programmer.win32
Date: Fri, 12 May 2023 06:41:04 -0700 (PDT)
In-Reply-To: <e665091a-17f8-42a5-af3c-e89d8ab33f75n@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=1.37.88.226; posting-account=CeHKkQoAAAAowY1GfiJYG55VVc0s1zaG
NNTP-Posting-Host: 1.37.88.226
References: <e665091a-17f8-42a5-af3c-e89d8ab33f75n@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <093a5017-58ad-4c38-ae01-7fb973608e4bn@googlegroups.com>
Subject: Re: cdecl to stdcall
From: mutazilah@gmail.com (muta...@gmail.com)
Injection-Date: Fri, 12 May 2023 13:41:04 +0000
Content-Type: text/plain; charset="UTF-8"
X-Received-Bytes: 1520
 by: muta...@gmail.com - Fri, 12 May 2023 13:41 UTC

Don't worry - got it.

; support routines
; written by Paul Edwards
; released to the public domain

..386p
..model flat

..code

extrn __imp__CreateDirectoryA@8:ptr
public _CreateDirectoryA
_CreateDirectoryA:
push 8[esp]
push 8[esp]
call __imp__CreateDirectoryA@8
ret
ret

end

Re: cdecl to stdcall

<72abd01d-79f6-40e4-94db-5bd9689df5f3n@googlegroups.com>

  copy mid

https://news.novabbs.org/devel/article-flat.php?id=532&group=comp.os.ms-windows.programmer.win32#532

  copy link   Newsgroups: comp.os.ms-windows.programmer.win32
X-Received: by 2002:a05:622a:1b89:b0:3ef:3cdf:c291 with SMTP id bp9-20020a05622a1b8900b003ef3cdfc291mr9410080qtb.13.1683918934449;
Fri, 12 May 2023 12:15:34 -0700 (PDT)
X-Received: by 2002:a05:620a:24c7:b0:74e:2894:7eb5 with SMTP id
m7-20020a05620a24c700b0074e28947eb5mr9213020qkn.8.1683918934263; Fri, 12 May
2023 12:15:34 -0700 (PDT)
Path: i2pn2.org!i2pn.org!usenet.blueworldhosting.com!diablo1.usenet.blueworldhosting.com!peer01.iad!feed-me.highwinds-media.com!news.highwinds-media.com!news-out.google.com!nntp.google.com!postnews.google.com!google-groups.googlegroups.com!not-for-mail
Newsgroups: comp.os.ms-windows.programmer.win32
Date: Fri, 12 May 2023 12:15:34 -0700 (PDT)
In-Reply-To: <093a5017-58ad-4c38-ae01-7fb973608e4bn@googlegroups.com>
Injection-Info: google-groups.googlegroups.com; posting-host=1.37.88.226; posting-account=CeHKkQoAAAAowY1GfiJYG55VVc0s1zaG
NNTP-Posting-Host: 1.37.88.226
References: <e665091a-17f8-42a5-af3c-e89d8ab33f75n@googlegroups.com> <093a5017-58ad-4c38-ae01-7fb973608e4bn@googlegroups.com>
User-Agent: G2/1.0
MIME-Version: 1.0
Message-ID: <72abd01d-79f6-40e4-94db-5bd9689df5f3n@googlegroups.com>
Subject: Re: cdecl to stdcall
From: mutazilah@gmail.com (muta...@gmail.com)
Injection-Date: Fri, 12 May 2023 19:15:34 +0000
Content-Type: text/plain; charset="UTF-8"
X-Received-Bytes: 1676
 by: muta...@gmail.com - Fri, 12 May 2023 19:15 UTC

Not sure if I've mentioned before, but there's a genuine
public domain partly masm-compatible assembler called
as86. And while masm accepted that previous code, as86
requires this variation that masm also supports.

And now SubC can use Windows functions! :-)

BFN. Paul.

..386p
..model flat

..code

extrn __imp__CreateDirectoryA@8:ptr
public _CreateDirectoryA
_CreateDirectoryA:
push 8[esp]
push 8[esp]
call [__imp__CreateDirectoryA@8]
ret
ret

end

1
server_pubkey.txt

rocksolid light 0.9.81
clearnet tor