[Vm-dev] Changes to plugin variable declarations?

Rob Withers reefedjib at yahoo.com
Fri Jul 23 08:14:01 UTC 2010


I am trying to compile DESPlugin, DSAPrims, MD5Plugin and SHA256Plugin with 
Cog.   I am getting errors with DESPlugin:

../../../src/plugins/DESPlugin/DESPlugin.c: In function `encryptwith':
../../../src/plugins/DESPlugin/DESPlugin.c:173: error: subscripted value is 
neit
her array nor pointer

Looking into that method, we have:

	self var: 'dataPtr' declareC: 'unsigned long *dataPtr'.
	self var: 'key' declareC: 'unsigned long *key'.
	self var: 'fVal' declareC: 'unsigned long fVal'.
	self var: 'work' declareC: 'unsigned long work'.
	self var: 'right' declareC: 'unsigned long right'.
	self var: 'left' declareC: 'unsigned long left'.


In browsing the code I see the following in #primitiveRead24BmpLine of 
BMPReadWriterPlugin (chosen at random):

	<var: #formBits type: 'unsigned int *'>

Does this mean my variable definitions should be:

	<var: #dataPtr type: 'unsigned long *'>
	<var: #key type: 'unsigned long *'>
	<var: #fVal type: 'unsigned long'>
	<var: #work type: 'unsigned long'>
	<var: #right type: 'unsigned long'>
	<var: #left type: 'unsigned long'>

?

WHat other changes are their?

TIA,
Rob 



More information about the Vm-dev mailing list