Re: [go-nuts] Re: Getting '[signal SIGSEGV: segmentation violation code=0x1 addr=0xffffffff04d07885 pc=0x7fe62f2d2922]' during cgo_call

2020-02-17 Thread K.S. Bhaskar
I think you may be right, and I think I was barking up the wrong tree. Sorry. Regards – Bhaskar On Monday, February 17, 2020 at 11:20:07 AM UTC-5, Nitish Saboo wrote: > > Hi, > > How can runtime.Keepalive be helpful here ? > > Thanks, > Nitish > > On Mon, Feb 17, 2

Re: [go-nuts] Re: Getting '[signal SIGSEGV: segmentation violation code=0x1 addr=0xffffffff04d07885 pc=0x7fe62f2d2922]' during cgo_call

2020-02-17 Thread K.S. Bhaskar
nsafe.Pointer(app)) > msg := C.CString(y) > defer C.free(unsafe.Pointer(msg)) > C.match(msg, C.size_t(len(y)), app, C.size_t(len(x))) > } > > Thanks, > Nitish > > On Mon, Feb 17, 2020 at 8:14 PM K.S. Bhaskar > wrote: > >> Chances are that a parameter or

[go-nuts] Re: Getting '[signal SIGSEGV: segmentation violation code=0x1 addr=0xffffffff04d07885 pc=0x7fe62f2d2922]' during cgo_call

2020-02-17 Thread K.S. Bhaskar
Chances are that a parameter or structure you are passing from Go to C is getting garbage collected by Go before the C code is done with it. Read the CGO documentaton – it's dense, but every sentence, every word, has a purpose. In case it helps, take a look at the video of my recent talk at

Re: [go-nuts] Panicking in public API ?

2020-01-09 Thread K.S. Bhaskar
Those are good guidelines. I'd like to add a couple of nuances. For “system” or “operations” errors (we have a database engine that executes in the address space of processes, so there can be errors such as an IO error or an inability to expand because of insufficient space in the file

[go-nuts] [ANN] YottaDB r1.28 released; Go wrapper now production grade

2019-09-13 Thread K.S. Bhaskar
pper and see what access to YottaDB data is like from Go. Thank you for using YottaDB software. Regards – Bhaskar K.S. Bhaskar President, YottaDB LLC 40 Lloyd Avenue, Suite 104 Malvern, PA 19355, USA bhas...@yottadb.com https://yottadb.com +1 (610) 644-1898 landline +1 (484) 873-4467 Google v

[go-nuts] Re: Odd runtime errors

2019-08-25 Thread K.S. Bhaskar
cgo is very picky, as is signal handling if you have Go and non-Go signal handlers. My advice is: - Understand everywhere that cgo is used. - Read every sentence in the cgo documentation, no matter how dense the prose is. - Read every sentence pertaining to signal handling if you

[go-nuts] Re: Announcing a Go API for YottaDB

2019-07-15 Thread K.S. Bhaskar
Apologies for the delayed reply; I have been traveling. The Go API is currently in a field test state (hopefully getting to production state in the next few weeks). The Go wrapper version to use with YottaDB r1.26 is the 'develop' branch at YDBGo. Or use YottaDB r1.24 and the master branch of

Re: [go-nuts] Is runtime.Keepalive() needed inside the methods for a receiver object?

2019-07-03 Thread K.S. Bhaskar
Thank you very much, Ian. Regards – Bhaskar On Wednesday, July 3, 2019 at 5:44:58 PM UTC-4, Ian Lance Taylor wrote: > > On Wed, Jul 3, 2019 at 1:32 PM K.S. Bhaskar > wrote: > > > > https://github.com/golang/go/issues/13347#issuecomment-158568326 seems > to s

[go-nuts] Is runtime.Keepalive() needed inside the methods for a receiver object?

2019-07-03 Thread K.S. Bhaskar
https://github.com/golang/go/issues/13347#issuecomment-158568326 seems to suggest runtime.KeepAlive() is not needed but it does not seem definitive. If there is a function such as the one below (from

Re: [go-nuts] Re: the Dominance of English in Programming Languages

2019-05-17 Thread K.S. Bhaskar
And let's not forget Indian English - between the countries in the Indian Sub-continent (India, Pakistan, Nepal, Bangladesh), that should add up to another couple hundred million at least, with its own peculiarities like "Horn OK Tata" on the back of every truck (sorry, lorry). Interestingly,

[go-nuts] Re: the Dominance of English in Programming Languages

2019-05-08 Thread K.S. Bhaskar
For historical reasons, languages and activities tend to be associated. Is the need for programmers to know relevant English technical terms any different from opera singers needing to know relevant Italian technical terms or fencers needing to know relevant French technical terms? Regards –

[go-nuts] Re: [URGENT] Pass array of string between Go and C library

2019-03-29 Thread K.S. Bhaskar
You can see how the YottaDB (https://yottadb.com) Go wrapper does it. Documentation of the API is at https://docs.yottadb.com/MultiLangProgGuide/goprogram.html and source code is at https://gitlab.com/YottaDB/Lang/YDBGo Regards – Bhaskar On Friday, March 29, 2019 at 5:16:05 AM UTC-4, Ashutosh

[go-nuts] Announcing a Go API for YottaDB

2019-02-09 Thread K.S. Bhaskar
l us what you think, either by posting here or by creating an Issue at https://gitlab.com/YottaDB/Lang/YDBGo/issues Thank you very much. Regards – Bhaskar (yes. it's my last name, but that's what everyone calls me) K.S. Bhaskar President, YottaDB LLC 40 Lloyd Avenue, Suite 104 Malvern, PA 19355,