Search Results

Search found 34 results on 2 pages for 'wyatt'.

Page 1/2 | 1 2  | Next Page >

  • Converting a time_t to string

    - by wyatt
    I have a time_t variable containing a timestamp which I'd like to store in a database, so I need it as a string. How would I convert it. Also, on the subject, how would I convert a timestamp string into a time_t varible? Thanks, Wyatt

    Read the article

  • Add AD Domain user to sudoers from the command line

    - by Wyatt Barnett
    I'm setting up an Ubuntu 11.04 server VM for use as a database server. It would make everyone's lives easier if we could have folks login using windows credentials and perhaps even make the machine work with the current AD-driven security we've got elsewhere. The first leg of this was really easy to accomplish -- apt-get install likewise-open and I was pretty much in business. The problem I'm having is getting our admins into the sudoers groups -- I can't seem to get anything to take. I've tried: a) usermod -aG sudoers [username] b) adding the user names in several formats (DOMAIN\user, user@domain) to the sudoers file. None of which seemed to take, I still get told "DOMAIN\user is not in the sudoers file. This incident will be reported." So, how do I add non-local users to the sudoers?

    Read the article

  • Why won't my install on Macbook work?

    - by Wyatt
    I am trying to install Ubuntu 12.04 on my Macbook. The CD drive is broken, so I am going from a USB flash drive I created. I can get it to "Try Ubuntu" perfectly fine, as a matter of fact I'm using it right now. However, I really want to install. Everything is partitioned, rEFIt is installed. I run the installer and I follow the guide at Apple Intel Installation I get to the install part of the installer, and after running it ends with a fatal grub error. Anyone know how to get past this? I feel like it has something to do with the fact that I don't get the last dialog box of the installer with the "advanced" tab used in the guide. Any help is greatly appreciated!

    Read the article

  • unlinked libraries in a makefile?

    - by wyatt
    I'm trying to install a libspopc, but when I run the make I get the following output: cc -Wall -Wextra -pedantic -pipe -fPIC -Os -DUSE_SSL -c session.c cc -Wall -Wextra -pedantic -pipe -fPIC -Os -DUSE_SSL -c queries.c cc -Wall -Wextra -pedantic -pipe -fPIC -Os -DUSE_SSL -c parsing.c cc -Wall -Wextra -pedantic -pipe -fPIC -Os -DUSE_SSL -c format.c cc -Wall -Wextra -pedantic -pipe -fPIC -Os -DUSE_SSL -c objects.c cc -Wall -Wextra -pedantic -pipe -fPIC -Os -DUSE_SSL -c libspopc.c rm -f libspopc*.a ar r libspopc-0.9n.a session.o queries.o parsing.o format.o objects.o libspopc.o ar: creating libspopc-0.9n.a ranlib libspopc-0.9n.a ln -s libspopc-0.9n.a libspopc.a rm -f libspopc*.so cc -o libspopc-0.9n.so -shared session.o queries.o parsing.o format.o objects.o libspopc.o ln -s libspopc-0.9n.so libspopc.so cc -o poptest1 -Wall -Wextra -pedantic -pipe -fPIC -Os -DUSE_SSL examples/poptest1.c -L. -lspopc -lssl -lcrypto /usr/local/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_globallookup': dso_dlfcn.c:(.text+0x2d): undefined reference to `dlopen' dso_dlfcn.c:(.text+0x43): undefined reference to `dlsym' dso_dlfcn.c:(.text+0x4d): undefined reference to `dlclose' /usr/local/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_pathbyaddr': dso_dlfcn.c:(.text+0x8f): undefined reference to `dladdr' dso_dlfcn.c:(.text+0xe9): undefined reference to `dlerror' /usr/local/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_bind_func': dso_dlfcn.c:(.text+0x491): undefined reference to `dlsym' dso_dlfcn.c:(.text+0x570): undefined reference to `dlerror' /usr/local/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_bind_var': dso_dlfcn.c:(.text+0x5f1): undefined reference to `dlsym' dso_dlfcn.c:(.text+0x6d0): undefined reference to `dlerror' /usr/local/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_unload': dso_dlfcn.c:(.text+0x735): undefined reference to `dlclose' /usr/local/lib/libcrypto.a(dso_dlfcn.o): In function `dlfcn_load': dso_dlfcn.c:(.text+0x817): undefined reference to `dlopen' dso_dlfcn.c:(.text+0x88e): undefined reference to `dlclose' dso_dlfcn.c:(.text+0x8d5): undefined reference to `dlerror' collect2: ld returned 1 exit status make: *** [poptest1] Error 1 A quick search suggested that this was due to libdl being unlinked, though this seems unlikely in a distributed library, particularly a seemingly relatively popular one. Could anything else be causing this? And if it is due to an unlinked library, how would I go about fixing it? Thanks

    Read the article

  • Export SharePoint Wiki to PDF from the Command Line

    - by Wyatt Barnett
    We use a SharePoint wiki* at the office to serve as a knowledgebase for our IT operations. Recently we went through a disaster recovery exercise where we realized we had a key hole in our plans: how do you restore the services if your instruction manual is down because some services are offline? Anyhow, we did realize that the wiki angle was definitely something we wanted to keep, but rather that we should explore a way to create offline backups of the wiki which could be easily read using common software we should be able to setup without any knowledge from the wiki. So, does anyone know of a good utility that can take a SharePoint wiki and dump it to PDF/Word/RTF/[INSERT HUMAN FRIENDLY FORMAT] easily from the command line? *-Yes, there are better solutions out there. But this was easy and used existing infrastructure and generally does what we need it to do.

    Read the article

  • Permissions Required for Sharepoint Backups

    - by Wyatt Barnett
    We are in the process of rolling out an extranet for some of our partners using WSS 3.0 as the platform. We already use it internally for a variety of things, and we are using the following powershell script to backup the server: param( $url="http://localhost", $backupFolder="c:\" ) [System.Reflection.Assembly]::LoadWithPartialName("Microsoft.SharePoint") $site= new-Object Microsoft.SharePoint.SPSite($url) $names=$site.WebApplication.Sites.Names foreach ($name in $names) { $n2 = "" if ($name.Length -eq 0) { $n2="ROOT" } else { $n2 = $name } $tmp=$n2.Replace("/", "_") + ".sbk" $saveas = "" if ($backupFolder.Length -eq 0) { $saveas = $tmp } else { $saveas = join-path -path $backupFolder -childPath $tmp } $site.WebApplication.Sites.Backup($name, $saveas, "true") write-host "$n2 backed up to $saveas." } This script works perfectly on the current installation running as our domain backup user. On the new box, it fails when ran as the backup user--claiming "The web application located at http://extranet/" could not be found. That url does, in fact, work so I'm fairly certain it isn't anything that dumb and rather is some permissions issue. Especially because, when executed from my security context, the script works perfectly. I have tried making the backup user a farm owner, as well as added him to the various site collection admin groups on the extranet. The one major difference between the extranet and the intranet server is that the extranet has an alternative access mapping (for https://xnet.example.com) and also uses forms authentication for that mapping. Anyhow, what permissions (or other voodoo) do I need to setup to get this script to work properly?

    Read the article

  • Mirroring the Global Address List on Blackberries

    - by Wyatt Barnett
    In times immemorial, back in the day when men were men and blackberries still took AA batteries, we rolled them out to our users for our 100 person operation. At that time, there was no such thing as address list lookups, so we were forced to hack a bit. The ingenious hack we came up with was to mirror the GAL as a public folder and then synch up blackberries to that. While there have been a few downsides here and there, they have been mere annoyances. And our users, having grown fat and prosperous in the intervening years, have been used to seeing every single employee and department here listed on their hand-held automatically. Alas, it appears that Outlook 2010 breaks this functionality as Blackberry desktop manager is completely incompatible with it. Moreover, this presents us with an opportunity to change things for the better given that public folders are going away next time we upgrade exchange. So, we are in search of a tool or technique that will allow us to mimic current functionality--that is to: Push an essentially arbitrary list of ~100 contacts to blackberry address books Said list shall be centrally updated Without requiring desktop manager or exchange public folders. Any suggestions, crowd?

    Read the article

  • A single AD user can't log into a single Mac bound to the domain (DirectoryServices error). How can I resolve this?

    - by Ben Wyatt
    On our campus, we have about 60 Macs joined to our Active Directory domain. Most users have no problems logging into Macs, as long as their accounts are configured correctly. However, we have one particular user who is unable to log in to just some of the Macs. He has no problem with most of them, but there is one group of them (all built from the same image) that he can't log in to. The machine in question is running OS X 10.6.2. The relevant entries from secure.log are below, with the hostname and username redacted. Aug 16 10:32:43 hostname SecurityAgent[4411]: Could not get the user record for username from DirectoryServices. Aug 16 10:32:43 hostname SecurityAgent[4411]: Will sleep 1 seconds and try again (retryCount = 4) Aug 16 10:32:44 hostname SecurityAgent[4411]: Could not get the user record for username from DirectoryServices. Aug 16 10:32:44 hostname SecurityAgent[4411]: Will sleep 2 seconds and try again (retryCount = 3) Aug 16 10:32:46 hostname SecurityAgent[4411]: Could not get the user record for username from DirectoryServices. Aug 16 10:32:46 hostname SecurityAgent[4411]: Will sleep 4 seconds and try again (retryCount = 2) Aug 16 10:33:10 hostname SecurityAgent[4411]: Could not get the user record for username from DirectoryServices. Aug 16 10:33:10 hostname SecurityAgent[4411]: Will sleep 8 seconds and try again (retryCount = 1) Aug 16 10:33:18 hostname SecurityAgent[4411]: User info context values set for username Aug 16 10:33:18 hostname SecurityAgent[4411]: unknown-user (username) login attempt PASSED for auditing Everything I've found online suggests that our use of Mobile Accounts is causing the issue. I turned that feature off, but I still can't log in as that user. id returns a record for his account, and nothing looks out of the ordinary. Has anyone here run into this before?

    Read the article

  • Compiling a program with a legacy version of gcc

    - by wyatt
    This is probably a very difficult problem to troubleshoot with the information I can practically provide, but I'm hoping someone might be able to at least point me in a possible direction. I'm trying to install HTK (http://htk.eng.cam.ac.uk/), which, according to this page needs to be installed using gcc 3.4. Their method of implementing backwards compatibility: #yum install compat-gcc-34-c++ compat-gcc-34 won't work for me as I'm running Ubuntu (On that note, I take it I can't simply install YUM and the subsequent package, since it's an entirely different distro, but if I'm wrong I'd love to hear it). I instead installed two versions of gcc 3.4 - 3.4.0 and 3.4.6 using instructions from this site. I then added the lines suggested by that page to the top of the makefile (on this note, what's the difference between makefile and makefile.in? I tried adding the lines to the top of both files regardless), both for version 3.4.0 and 3.4.6, but both failed. I also tried, on the off-chance, compiling it with my current version (4.4.1), but that also failed. I got the errors: (cd HTKLib && make HTKLib.a) \ || case "" in k) fail=yes;; ) exit 1;; esac; make1: Entering directory /home/charles/bin/htk-3.4/HTKLib' gcc -ansi -D_SVID_SOURCE -DOSS_AUDIO -D'ARCH="i686"' -Wall -Wno-switch -g -O2 -I. -c -o HGraf.o HGraf.c HGraf.c:73:77: error: X11/Xlib.h: No such file or directory HGraf.c:74:23: error: X11/Xutil.h: No such file or directory HGraf.c:75:21: error: X11/Xos.h: No such file or directory HGraf.c:77:27: error: X11/keysymdef.h: No such file or directory HGraf.c:87: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token HGraf.c:88: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘rootW’ HGraf.c:91: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘theCmap’ HGraf.c:92: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘theGC’ HGraf.c:93: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘gcs’ HGraf.c:95: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token HGraf.c:96: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘report’ HGraf.c:97: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘hints’ HGraf.c:111: error: ‘GXcopy’ undeclared here (not in a function) HGraf.c:111: error: ‘GXor’ undeclared here (not in a function) HGraf.c:111: error: ‘GXxor’ undeclared here (not in a function) HGraf.c:111: error: ‘GXinvert’ undeclared here (not in a function) HGraf.c:151: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token HGraf.c: In function ‘InstallFonts’: HGraf.c:164: error: ‘FontInfo’ undeclared (first use in this function) HGraf.c:164: error: (Each undeclared identifier is reported only once HGraf.c:164: error: for each function it appears in.) HGraf.c:164: warning: implicit declaration of function ‘XLoadQueryFont’ HGraf.c:164: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:167: error: ‘DefaultFont’ undeclared (first use in this function) HGraf.c: At top level: HGraf.c:176: error: expected ‘)’ before ‘*’ token HGraf.c: In function ‘HGetEvent’: HGraf.c:219: error: ‘XEvent’ undeclared (first use in this function) HGraf.c:219: error: expected ‘;’ before ‘xev’ HGraf.c:223: warning: implicit declaration of function ‘XFlush’ HGraf.c:223: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:225: warning: implicit declaration of function ‘XEventsQueued’ HGraf.c:225: error: ‘QueuedAfterFlush’ undeclared (first use in this function) HGraf.c:226: warning: implicit declaration of function ‘XNextEvent’ HGraf.c:226: error: ‘xev’ undeclared (first use in this function) HGraf.c:228: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:230: error: ‘ButtonPress’ undeclared (first use in this function) HGraf.c:235: error: ‘ButtonRelease’ undeclared (first use in this function) HGraf.c:240: error: ‘MotionNotify’ undeclared (first use in this function) HGraf.c:245: error: ‘KeyPress’ undeclared (first use in this function) HGraf.c:249: warning: implicit declaration of function ‘DecodeKeyPress’ HGraf.c:251: error: ‘KeyRelease’ undeclared (first use in this function) HGraf.c:257: error: ‘Expose’ undeclared (first use in this function) HGraf.c: In function ‘HEventsPending’: HGraf.c:281: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:281: error: ‘QueuedAfterFlush’ undeclared (first use in this function) HGraf.c: In function ‘HMousePos’: HGraf.c:288: error: ‘Window’ undeclared (first use in this function) HGraf.c:288: error: expected ‘;’ before ‘root’ HGraf.c:293: warning: implicit declaration of function ‘XQueryPointer’ HGraf.c:293: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:293: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:293: error: ‘root’ undeclared (first use in this function) HGraf.c:293: error: ‘child’ undeclared (first use in this function) HGraf.c: In function ‘InstallColours’: HGraf.c:311: error: ‘XColor’ undeclared (first use in this function) HGraf.c:311: error: expected ‘;’ before ‘greyDef’ HGraf.c:317: warning: implicit declaration of function ‘XParseColor’ HGraf.c:317: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:317: error: ‘theCmap’ undeclared (first use in this function) HGraf.c:317: error: ‘colourDef’ undeclared (first use in this function) HGraf.c:320: warning: implicit declaration of function ‘XAllocColor’ HGraf.c:334: error: ‘whiteDef’ undeclared (first use in this function) HGraf.c:334: warning: implicit declaration of function ‘XQueryColor’ HGraf.c:335: error: ‘blackDef’ undeclared (first use in this function) HGraf.c:341: error: ‘greyDef’ undeclared (first use in this function) HGraf.c: In function ‘HSetColour’: HGraf.c:361: warning: implicit declaration of function ‘XSetForeground’ HGraf.c:361: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:361: error: ‘gcs’ undeclared (first use in this function) HGraf.c: In function ‘HSetGrey’: HGraf.c:370: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:370: error: ‘gcs’ undeclared (first use in this function) HGraf.c: In function ‘HDrawLines’: HGraf.c:388: warning: implicit declaration of function ‘XDrawLines’ HGraf.c:388: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:388: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:388: error: ‘theGC’ undeclared (first use in this function) HGraf.c:388: error: ‘XPoint’ undeclared (first use in this function) HGraf.c:388: error: expected expression before ‘)’ token HGraf.c: In function ‘HDrawRectangle’: HGraf.c:395: warning: implicit declaration of function ‘XDrawRectangle’ HGraf.c:395: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:395: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:395: error: ‘theGC’ undeclared (first use in this function) HGraf.c: In function ‘HFillRectangle’: HGraf.c:402: warning: implicit declaration of function ‘XFillRectangle’ HGraf.c:402: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:402: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:402: error: ‘theGC’ undeclared (first use in this function) HGraf.c: In function ‘HDrawLine’: HGraf.c:408: warning: implicit declaration of function ‘XDrawLine’ HGraf.c:408: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:408: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:408: error: ‘theGC’ undeclared (first use in this function) HGraf.c: In function ‘HFillPolygon’: HGraf.c:414: warning: implicit declaration of function ‘XFillPolygon’ HGraf.c:414: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:414: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:414: error: ‘theGC’ undeclared (first use in this function) HGraf.c:414: error: ‘XPoint’ undeclared (first use in this function) HGraf.c:414: error: expected expression before ‘)’ token HGraf.c: In function ‘HDrawArc’: HGraf.c:427: warning: implicit declaration of function ‘XDrawArc’ HGraf.c:427: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:427: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:427: error: ‘theGC’ undeclared (first use in this function) HGraf.c: In function ‘HFillArc’: HGraf.c:440: warning: implicit declaration of function ‘XFillArc’ HGraf.c:440: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:440: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:440: error: ‘theGC’ undeclared (first use in this function) HGraf.c: In function ‘HPrintf’: HGraf.c:451: warning: implicit declaration of function ‘XDrawString’ HGraf.c:451: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:451: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:451: error: ‘theGC’ undeclared (first use in this function) HGraf.c: In function ‘HCopyArea’: HGraf.c:457: warning: implicit declaration of function ‘XCopyArea’ HGraf.c:457: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:457: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:457: error: ‘theGC’ undeclared (first use in this function) HGraf.c: In function ‘HPlotVector’: HGraf.c:476: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:476: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:476: error: ‘theGC’ undeclared (first use in this function) HGraf.c: In function ‘HSetFontSize’: HGraf.c:490: error: ‘CurrentFont’ undeclared (first use in this function) HGraf.c:490: error: ‘DefaultFont’ undeclared (first use in this function) HGraf.c:499: error: ‘FontInfo’ undeclared (first use in this function) HGraf.c:502: warning: implicit declaration of function ‘XSetFont’ HGraf.c:502: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:502: error: ‘gcs’ undeclared (first use in this function) HGraf.c: In function ‘HSetLineWidth’: HGraf.c:511: warning: implicit declaration of function ‘XSetLineAttributes’ HGraf.c:511: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:511: error: ‘gcs’ undeclared (first use in this function) HGraf.c:511: error: ‘LineSolid’ undeclared (first use in this function) HGraf.c:511: error: ‘JoinRound’ undeclared (first use in this function) HGraf.c:511: error: ‘FillSolid’ undeclared (first use in this function) HGraf.c: In function ‘HSetXMode’: HGraf.c:517: error: ‘theGC’ undeclared (first use in this function) HGraf.c:517: error: ‘gcs’ undeclared (first use in this function) HGraf.c: In function ‘CentreX’: HGraf.c:523: warning: implicit declaration of function ‘XTextWidth’ HGraf.c:523: error: ‘CurrentFont’ undeclared (first use in this function) HGraf.c: In function ‘CentreY’: HGraf.c:529: error: ‘CurrentFont’ undeclared (first use in this function) HGraf.c: In function ‘HTextWidth’: HGraf.c:535: error: ‘CurrentFont’ undeclared (first use in this function) HGraf.c: In function ‘HTextHeight’: HGraf.c:541: error: ‘CurrentFont’ undeclared (first use in this function) HGraf.c: In function ‘HDrawImage’: HGraf.c:550: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘*’ token HGraf.c:550: error: ‘xi’ undeclared (first use in this function) HGraf.c:557: warning: implicit declaration of function ‘XDestroyImage’ HGraf.c:558: warning: implicit declaration of function ‘XGetImage’ HGraf.c:558: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:558: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:558: error: ‘AllPlanes’ undeclared (first use in this function) HGraf.c:558: error: ‘XYPixmap’ undeclared (first use in this function) HGraf.c:562: warning: implicit declaration of function ‘XPutPixel’ HGraf.c:564: warning: implicit declaration of function ‘XPutImage’ HGraf.c:564: error: ‘theGC’ undeclared (first use in this function) HGraf.c: In function ‘HFlush’: HGraf.c:570: error: ‘theDisp’ undeclared (first use in this function) HGraf.c: In function ‘InitGCs’: HGraf.c:780: error: ‘XGCValues’ undeclared (first use in this function) HGraf.c:780: error: expected ‘;’ before ‘values’ HGraf.c:783: error: ‘GCLineWidth’ undeclared (first use in this function) HGraf.c:783: error: ‘GCFunction’ undeclared (first use in this function) HGraf.c:783: error: ‘GCForeground’ undeclared (first use in this function) HGraf.c:785: error: ‘values’ undeclared (first use in this function) HGraf.c:788: error: ‘gcs’ undeclared (first use in this function) HGraf.c:788: warning: implicit declaration of function ‘XCreateGC’ HGraf.c:788: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:788: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:790: error: ‘GCPlaneMask’ undeclared (first use in this function) HGraf.c: In function ‘InitGlobals’: HGraf.c:800: warning: implicit declaration of function ‘DefaultScreen’ HGraf.c:800: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:801: error: ‘theCmap’ undeclared (first use in this function) HGraf.c:801: warning: implicit declaration of function ‘DefaultColormap’ HGraf.c:802: error: ‘rootW’ undeclared (first use in this function) HGraf.c:802: warning: implicit declaration of function ‘RootWindow’ HGraf.c:803: error: ‘theGC’ undeclared (first use in this function) HGraf.c:803: warning: implicit declaration of function ‘DefaultGC’ HGraf.c:804: error: ‘theVisual’ undeclared (first use in this function) HGraf.c:804: warning: implicit declaration of function ‘DefaultVisual’ HGraf.c:805: warning: implicit declaration of function ‘DisplayCells’ HGraf.c:806: warning: implicit declaration of function ‘DisplayWidth’ HGraf.c:807: warning: implicit declaration of function ‘DisplayHeight’ HGraf.c:808: warning: implicit declaration of function ‘DisplayPlanes’ HGraf.c:809: warning: implicit declaration of function ‘WhitePixel’ HGraf.c:810: warning: implicit declaration of function ‘BlackPixel’ HGraf.c: In function ‘MakeXGraf’: HGraf.c:817: error: ‘Window’ undeclared (first use in this function) HGraf.c:817: error: expected ‘;’ before ‘window’ HGraf.c:818: error: ‘XSetWindowAttributes’ undeclared (first use in this function) HGraf.c:818: error: expected ‘;’ before ‘setwinattr’ HGraf.c:823: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:823: warning: implicit declaration of function ‘XOpenDisplay’ HGraf.c:824: warning: implicit declaration of function ‘XDisplayName’ HGraf.c:828: error: ‘parent’ undeclared (first use in this function) HGraf.c:829: error: ‘window’ undeclared (first use in this function) HGraf.c:829: warning: implicit declaration of function ‘XCreateSimpleWindow’ HGraf.c:831: error: ‘CWBackingStore’ undeclared (first use in this function) HGraf.c:831: error: ‘setwinattr’ undeclared (first use in this function) HGraf.c:831: error: ‘WhenMapped’ undeclared (first use in this function) HGraf.c:832: warning: implicit declaration of function ‘XChangeWindowAttributes’ HGraf.c:834: error: ‘hints’ undeclared (first use in this function) HGraf.c:834: error: ‘PPosition’ undeclared (first use in this function) HGraf.c:834: error: ‘PSize’ undeclared (first use in this function) HGraf.c:834: error: ‘PMaxSize’ undeclared (first use in this function) HGraf.c:834: error: ‘PMinSize’ undeclared (first use in this function) HGraf.c:841: warning: implicit declaration of function ‘XSetStandardProperties’ HGraf.c:841: error: ‘None’ undeclared (first use in this function) HGraf.c:843: warning: implicit declaration of function ‘XSelectInput’ HGraf.c:843: error: ‘ExposureMask’ undeclared (first use in this function) HGraf.c:843: error: ‘KeyPressMask’ undeclared (first use in this function) HGraf.c:843: error: ‘ButtonPressMask’ undeclared (first use in this function) HGraf.c:844: error: ‘ButtonReleaseMask’ undeclared (first use in this function) HGraf.c:844: error: ‘PointerMotionHintMask’ undeclared (first use in this function) HGraf.c:844: error: ‘PointerMotionMask’ undeclared (first use in this function) HGraf.c:845: warning: implicit declaration of function ‘XMapWindow’ HGraf.c:845: error: ‘theWindow’ undeclared (first use in this function) HGraf.c:850: error: ‘report’ undeclared (first use in this function) HGraf.c:851: error: ‘Expose’ undeclared (first use in this function) HGraf.c:852: warning: implicit declaration of function ‘XSendEvent’ HGraf.c:852: error: ‘False’ undeclared (first use in this function) HGraf.c: In function ‘TermHGraf’: HGraf.c:861: error: ‘theDisp’ undeclared (first use in this function) HGraf.c:862: warning: implicit declaration of function ‘XCloseDisplay’ make[1]: *** [HGraf.o] Error 1 make[1]: Leaving directory/home/charles/bin/htk-3.4/HTKLib' make: ** [HTKLib/HTKLib.a] Error 1 Thank you for any help you can provide.

    Read the article

  • run a function every x seconds in c++

    - by wyatt
    I'm trying to build a feed reader in C++, so I need the program to check for new feeds intermittently. However, the user needs still to be able to interact with the program, so the suggestion that I seem to keep finding, to have the system wait, doesn't work for me. Can anyone suggest a better solution, say a timer that runs in the background or something? Thanks, Charles

    Read the article

  • C++ includes with and without .h

    - by wyatt
    I've never noticed it making any difference whether or not I include the .h at the end of an include, so I've always ignored the meaning, but I've just noticed in a particular program of mine, I get the error "memcpy was not declared in this scope" if I include "string", but not if I include "string.h". First of all, I was wondering the specific cause of this, but also generally the difference between the two. At the same time, if someone could explain the difference between includes in angular brackets and those in quotation marks, It'd be much appreciated.

    Read the article

  • Calling a function in an iframe from a parent in firefox

    - by wyatt
    I'm trying to call a function, test(), of an iframe from the parent document using the code subframe.test(); subframe refers correctly to the iframe, alert(subframe) returns [object HTMLIFrameElement], and the function runs in both IE7 and opera (9.23), but not firefox (3.0), chrome (3.0) or safari (3.03 beta windows). I assume these browsers support the functionality, so wondering if perhaps I'm using an incorrect call which IE and Opera support anyway, which wouldn't surprise me.

    Read the article

  • Training speech recognition software

    - by wyatt
    A little left field, but I'm trying to train a speech recognition program and the guidelines suggest that I attempt to speak clearly but naturally. I notice, however, that when one speaks naturally each word tends to drift into the next, resulting in a rather ambiguous boundary between the words. One the one hand, speaking in a more stilted manner would seem to aid the computer in recognising the phonemes, but on the other it would tend to make it less likely to understand more natural speech. Anyone knowledgeable in the field out there who can suggest which of the two approaches is more effective? Thanks

    Read the article

  • C++ casted realloc causing memory leak

    - by wyatt
    I'm using a function I found here to save a webpage to memory with cURL: struct WebpageData { char *pageData; size_t size; }; size_t storePage(void *input, size_t size, size_t nmemb, void *output) { size_t realsize = size * nmemb; struct WebpageData *page = (struct WebpageData *)output; page->pageData = (char *)realloc(page->pageData, page->size + realsize + 1); if(page->pageData) { memcpy(&(page->pageData[page->size]), input, realsize); page->size += realsize; page->pageData[page->size] = 0; } return realsize; } and find the line: page->pageData = (char *)realloc(page->pageData, page->size + realsize + 1); is causing a memory leak of a few hundred bytes per call. The only real change I've made from the original source is casting the line in question to a (char *), which my compiler (gcc, g++ specifically if it's a c/c++ issue, but gcc also wouldn't compile with the uncast statement) insisted upon, but I assume this is the source of the leak. Can anyone elucidate? Thanks

    Read the article

  • buffer size for socket connection in c++

    - by wyatt
    I'm trying to build a basic POP3 mail client in C/++, but I've run into a bit of an issue. Since you have to define the buffer size when building the program, but a message can be arbitrarily large, how do you, say, get the mail server to send it to you in parts? And if this isn't the correct means of solving the problem, what is? And while I'm here, can anyone confirm for me that RFC 2822 is still the current document defining email layout? Thanks

    Read the article

  • Getting a unix timestamp as a string in C++

    - by wyatt
    I'm using the function time() in order to get a timestamp in C++, but, after doing so, I need to convert it to a string. I can't use ctime, as I need the timestamp itself (in its 10 character format). Trouble is, I have no idea what form a time_t variable takes, so I don't know what I'm converting it from. cout handles it, so it must be a string of some description, but I have no idea what. If anyone could help me with this it'd be much appreciated, I'm completely stumped. Alternately, can you provide the output of ctime to a MySQL datetime field and have it interpreted correctly? I'd still appreciate an answer to the first part of my question for understanding's sake, but this would solve my problem.

    Read the article

  • Accessing a webpage in C++

    - by wyatt
    Is there a good, simple library which allows C++ to load a webpage? I just want to grab the source as text. I'm not using any IDE or significant library, just straight command line. Tangentially, is there something fundamental I'm missing about programming in C++? I would think any language in common use today would have droves of web-based functionality, being so central to computer usage, but I can find next to no discussion on how to accomplish it. I realise C++ significantly predates the modern internet, so it lacking any core ability in the regard is reasonable, but the fact that relevant libraries seem so sparse is baffling. Thanks for your help.

    Read the article

  • Class destructor memory handling in C++

    - by wyatt
    What potential memory leaks won't an implicit destructor handle? I know that if you have anything stored on the heap it won't handle it, and if you have a connection to a file or a database, that needs to be handled manually. Is there anything else? What about, say, non-base data types like vectors? Also, in an explicit destructor, need you destroy non-heap variables which would have been destroyed by the implicit, or are they handled automatically? Thanks

    Read the article

  • variables in abstract classes C++

    - by wyatt
    I have an abstract class CommandPath, and a number of derived classes as below: class CommandPath { public: virtual CommandResponse handleCommand(std::string) = 0; virtual CommandResponse execute() = 0; virtual ~CommandPath() {} }; class GetTimeCommandPath : public CommandPath { int stage; public: GetTimeCommandPath() : stage(0) {} CommandResponse handleCommand(std::string); CommandResponse execute(); }; All of the derived classes have the member variable 'stage'. I want to build a function into all of them which manipulates 'stage' in the same way, so rather than defining it many times I thought I'd build it into the parent class. I moved 'stage' from the private sections of all of the derived classes into the protected section of CommandPath, and added the function as follows: class CommandPath { protected: int stage; public: virtual CommandResponse handleCommand(std::string) = 0; virtual CommandResponse execute() = 0; std::string confirmCommand(std::string, int, int, std::string, std::string); virtual ~CommandPath() {} }; class GetTimeCommandPath : public CommandPath { public: GetTimeCommandPath() : stage(0) {} CommandResponse handleCommand(std::string); CommandResponse execute(); }; Now my compiler tells me for the constructor lines that none of the derived classes have a member 'stage'. I was under the impression that protected members are visible to derived classes? The constructor is the same in all classes, so I suppose I could move it to the parent class, but I'm more concerned about finding out why the derived classes aren't able to access the variable. Also, since previously I've only used the parent class for pure virtual functions, I wanted to confirm that this is the way to go about adding a function to be inherited by all derived classes.

    Read the article

  • Exclude subexpression from regexec in c++

    - by wyatt
    Suppose I was trying to match the following expression using regex.h in C++, and trying to obtain the subexpressions contained: /^((1|2)|3) (1|2)$/ Suppose it were matched against the string "3 1", the subexpressions would be: "3 1" "3" "1" If, instead it were matched against the string "2 1", the subexpressions would be: "2 1" "2" "2" "1" Which means that, depending on how the first subexpression evaluates, the final one is in a different element in the pmatch array. I realise this particular example is trivial, as I could remove one of the sets of brackets, or grab the last element of the array, but it becomes problematic in more complicated expressions. Suppose all I want are the top-level subexpressions, the ones which aren't subexpressions of other subexpressions. Is there any way to only get them? Or, alternatively, to know how many subexpressions are matched within a subexpression, so that I can traverse the array irrespective of how it evaluates? Thanks

    Read the article

  • Overinclusion of libraries C++

    - by wyatt
    I'm reading about how to put a makefile together, but no-one seems to mention what to do if your files require different sets of libraries, they all seem to use the same set of libraries for each file. Since it seems unlikely that every single file has the same libraries, I take it the list they use must amalgamate all of the libraries required across the project. I just wanted to know if there's any downside to including too many libraries, or if the compiler works out which ones are needed and ignores the rest? Thanks

    Read the article

  • kill a process in bash

    - by wyatt
    How do I kill a process which is running in bash - for example, suppose I open a file: $ gedit file.txt is there any way within the command prompt to close it? This example is fairly trivial, since I could just close the window, but it seems to come up a bit, particularly when I mistype commands. Also is there any way to escape an executable which is running? This probably has the same solution, but I thought I'd ask anyway. Thanks

    Read the article

1 2  | Next Page >